AStateOfCode/AsseticAngularJsBundle — pull request #3 by piotr-cz (2014-10-01 09:42:54+00:00)
Title: Using one Module name across Bundle

At this moment angular filter creates module for each template, and it's not possible to make sure that generated module executes before application does (unless you type all generated templates as dependencies), thus not populating $templateCache.

Solution that works for me:

1) Define bundle module in application
```js
angular.module('MyBundle', []);
```
2) Add generated file with new contents:
```js
angular.module("MyBundle.templates").run(["$templateCache", function($templateCache) {$templateCache.put("
// ...
");
```

3) Define dependency in application:
```js
angular.module('MyBundle.core', [
// Angular modules
'ngRoute',
// Templates
'MyBundle.templates'
]);
```