chore(amd): amd distribution - #97
Conversation
the default build is done for `commonjs` only. Since consumers might using other bundlers, in my case requirejs - which requires amd bundles - it would be great to create another compile target. typically a structure for multi-targets would be lib -> umd -> commonjs -> amd -> ... Since i didn't want to override your project structure, amd here is now compiled to `dist/amd`
|
@zewa666 generally I am not opposed an idea. How did you know that it does what you want? I see that usually for amd everything gets bundled in one file, e.g. like monaco is bundled. Does having multiple files work for you? Do you have an example? |
|
Our example is hard to share as it involves large parts and various dependencies. AMD targets do not necessarily need to be bundled. Actually having the files seperated is desired in order to be able to lazy load single files as opposed to webpack bundles. We tested the PR here against our solution and it worked. |
|
Ideally the resulting folder structure should be changed so that lib contains subfolders per target but this ist certainly good enough for my project to keep going. Thx |
|
Yes, but it will be a breaking change for downstream dependencies. I would prefer to stick to the current structure. |
|
@zewa666 published 0.7.1 with amd |
|
Thanks for the super fast response. We're currently in the process of updating to the new version and fixing our Service registrations, so this helps to have cleaner and easier builds without the need to run a fork |
the default build is done for
commonjsonly. Since consumers might using other bundlers, in my case requirejs - which requires amd bundles - it would be great to create another compile target.typically a structure for multi-targets would be
lib
-> umd
-> commonjs
-> amd
-> ...
Since i didn't want to override your project structure, amd here is now compiled to
dist/amd