Is it possible to share code between CloudCode tasks and app views?

For example, can you import into CloudCode from an App Package?