I have multi - modular Angular 13 application, where modules are loaded using lazy - loading. The problem is that generated Angular files like main.[hash].js, pollyfils.[hash].js and runtime.[hash].js are located NOT at the site root. The structure looks like following:
/index.html
/mysitefolder/main.f29052602897eb02.js
/mysitefolder/styles.755cfc65dad8627d.css
/mysitefolder/polyfills.eca354b64e370005.js
/mysitefolder/runtime.54752149a889ba60.js
/mysitefolder/815.d3bd01384abd247c.js
The Angular.json file has following setting:
"outputPath": "../public/mysitefolder"
When application runs, it tries to load the chunk file 815.d3bd01384abd247c.js
from the application root, not from the it's actual location, obviously chunk load fails. How to fix this? Is there any setting to tell Angular to load chunks for lazy - loaded modules from the specific /mysitefolder/
location?