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
Group all Angular packages that have the same version as @angular/core, and
also show information for schematics, devkit and others that might not be
in the package.json but still installed. Those versions are important.
We made too many shortcuts for passing data in and custom schematics could not
work properly.
This is temporary as we will likely move some more logic into schematics tooling
to be able to pass only the raw args and the CLI config, but for now this is
enough to unblock AngularMix.
when ng e2e --serve=true is run and the build is not successful e2e task
should not be run
previously the e2e task was run even if build was a failure which will
obviously result in failure of test cases
now if errors are detected in build the e2e task will not be run
update docs as well to reflect this behaviour
Closes#7567
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.