Question about bundling. I'm trying to share a set of Angular 1.x modules as a single JSPM package that other Angular 1.x apps can consume. Here's what I'm trying to do: given a file structure like this:
root/
├── src
│ ├── my-module
│ │ └── my-service.js
│ ├── my-other-module
│ │ └── my-other-service.js
│ └── bootstrap.js
├── jspm_packages
├── config.js
├── index.html
└── package.json
How can I bundle my-module and my-other-module into a single file that will allow me to consume the contents of the bundle in another application like this?
import * as MyService from 'mybundle/my-module/my-service';
import * as MyOtherService from 'mybundle/my-other-module/my-other-service';
assuming I've dropped this bundle into my consuming app at thirdparty/my-bundle.js and added this to my consuming app's config.js:
map: {
"my-bundle": "third-party/my-bundle.js"
}
This is what I've tried (using the systemjs-builder npm package):
builder.bundle('[src/**/*]', 'dist/my-bundle.js');
Is there a way I can bundle my Angular modules so that I can consume them in the way I'm expecting? Or is there a better way to package Angular 1.x modules for use as a JSPM module?