The node only `global` object had been left in because it used to cause a build size regression with Angular.
This doesn't seem to be the case anymore so it should be removed because it causes problematic interactions with some libraries.
Fix#5804
Supersedes #7931
Forcing TypeScript to output commonjs modules instead of es2015 modules drastically improves rebuild speeds, especially for AOT.
This PR forces this option on the following modes:
- `ng build --watch --target=development`
- `ng serve --target=development`
- `ng test --code-coverage=false`
Please note that `--target=development` and `--code-coverage=false` are the defaults.
See https://github.com/webpack/webpack/issues/5863 for the webpack issue.
This should fix errors like the one below for 0.6.0:
```
URL Loader Invalid Options
options['name'] should NOT have additional properties
options.limit should be number
```
We feel build `--build-optimizer` is stable enough to not be experimental anymore.
This PR defaults `build-optimizer` when using Angular 5+ on a production build with `--aot`.
It can still be turned off with `--no-build-optimizer` (or `--build-optimizer=false`).
Fix#8050
This flag allows people who know what theyre doing to bundle the
server build together with all dependencies. It should only be
used when the whole rendering process is part of the main.ts
or one of its dependencies.
Fixes#7903.
Aim to resolve#7514 by including postcss-custom-properties. This will generate extra rules in CSS when a `var()` is used to allow for compatibility with older IE browsers that do not support the feature.
This adds the new parameter `missingTranslation` for AoT that was added in angular/angular/pull/15987 and that lets you define the MissingTranslationStrategy
Adds sourcemap and minification to javascript added via the `scripts` array in `.angular-cli.json`.
`script-loader` is no longer used, which should help with CSP since it used `eval`.
Scripts will no longer appear in the console output for `ng build`, as they are now assets instead of webpack entry points.
It's no longer possible to have the `output` property of both a `scripts` and a `styles` entry pointing to the same file. This wasn't officially supported or listed in the docs, but used to be possible.
Fix#2796Fix#7226Fix#7290
Related to #6872