This is useful when you don't want the server to rebuild in the middle of something.
A good example is when running e2e tests. Especially on larger suites, one would prefer to continue working while the build is tested without compromising tests.
This will break tests on #4744. They should be adjusted to add the `--watch` flag since they depend on the live reload behaviour during `ng e2e`.
Heavily based on @jsanchezgarcia work in #4476.
Fix#3857
BREAKING CHANGE:
A new environmentSource entry replaces the previous source entry inside environments.
To migrate the code follow the example below:
Before:
```
"environments": {
"source": "environments/environment.ts",
"dev": "environments/environment.ts",
"prod": "environments/environment.prod.ts"
}
```
After:
```
"environmentSource": "environments/environment.ts",
"environments": {
"dev": "environments/environment.ts",
"prod": "environments/environment.prod.ts"
}
```
Allows you to run ng build --json which generates dist/stats.json. This can then be used with things like the webpack-bundle-analyzer or https://webpack.github.io/analyse/Fix#3179
Fix https://github.com/angular/angular-cli/issues/4138
BREAKING CHANGE:
- `--extractCss` defaults to `false` on all `--dev` (`ng build` with no flags uses `--dev`)
- `--aot` defaults to true in `--prod`
- the alias for `--output-path` is now `-op` instead of `-o`
Having css extraction on all the time makes dev rebuild times very slow for global styles.
This flag defaults to false on dev targets and true on prod targets.