Description
It would be great if "input" and "output" optional paths were added to "index" in angular-cli.json. There are scenarios that can not be covered with current implementation. (even using deployUrl)
With the current implementation the path of index.html after build is forced to be the same with the location during development. This is not always the case. An example is when folder structure in development is different than production. In such case the output path of the index.html can not be the same.
For example in angular-cli.json:
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"project": {
"name": "orco-frontend"
},
"apps": [
{
"name": "dm",
"root": "src",
"outDir": "dist/dm",
"assets": [
{ "glob": "/*", "input": "dm/assets/", "output": "./assets/" },
{ "glob": "favicon.ico", "input": "dm/", "output": "./" },
{ "glob": "/*", "input": "shared/assets", "output": "./assets/" }
],
"index": "dm/index.html",
"deployUrl": "./",
In this example there is an app (dm) in src folder. The index.html file after build ends up in dist/dm/dm/index.html while it needs to be in dist/dm/index.html.
Even if you change outDir to the folder: "new location", index.html will still be built to the folder "new location"/dm/index.html. All the rest of the necessary files of the build will end up in the folder "new location" which is not the proper file/folder structure. This should not be forced to happen.