I am working on an open source platform, similar to WordPress and other CMS apps, but focusing on interopability with the typical Java build pipeline.
The goal is to create some reusable libraries that provide build/runtime dependencies for developers to create feature modules that can be applied to the platform after it's deployed [plugins].
I created an original version that did this well, using AngularJS + Spring framework.
Essentially it would scan dependency jars for static files matching a specific pattern, create MVC resource resolution to the files, then include those file urls into the index page.
This effectively allowed a resource library to include server and client side resources to extend the running platform.
*BUT! A coworker said my font-end was out of date, that I needed to update Angular =P
So I've began rewriting the UI in Angular 4 as a separate resources dependency that can be used in a feature module project for testing, before publishing as a jar.
I really love Angular 4 [TS] as it's more like developing server code which I am proficient at.
Getting to the point... if a feature modules provides client side resources, how do I load them at runtime?
I think I could use JIT and load the js paths in the browser, but I want to use AOT for performance reasons.
I'm considering - unpacking the resources, running a compilation, then serving the page.
Or is there a way to dynamically load an Angular module after the AOT has already been performed?
Referenced Project - https://github.com/savantly-net/sprout-platform