The Webpack `Stats.toJson` function can be expensive. A new programmatic option is now available (`shouldProvideStats`) which can be used to control whether the `webpackStats` property on the builder output object is present. For backwards compatibility, the option is currently enabled by default.
With Webpack 5, passing the watch configuration option into the `webpack` factory function will cause the Webpack compiler to assume it should immediately start watching which requires a callback to be passed as well. Since the execution of the compiler is handled later in the process, a callback at the compiler creation stage is undesirable and could result in potentially breaking changes to accomplish.
This change removes some unneeded casts and provides support for building against Webpack 5. Webpack 5 typings currently do not contain certain types (for example, `Compiler.Handler`). Webpack 5 also uses `Set` in many places instead of arrays.
This commit makes a few minor changes to enable syncing the CLI repository
into google3.
1. mark pkg_tar and pkg_npm as external
2. remove dependencies (marked as comment) which are stale in google3
3. remove TS files generated from JSON schema in BUILD files since these
files are compiled and added to the g3 codebase at sync time
4. Some minor typing changes
5. Remove duplicate licenses
6. mark dependencies which are not available in g3 as external
7. Immediately type the result of JSON.parse() as required by g3 linter.
Otherwise, the type defaults to `any`.
With this change we update the target and module settings of various compilation units.
- We replace ES5 target in protractor. Protractor runs on Node.Js which support ES2018
- For applications we now use `ES2020` instead of `ESNext` as a module to avoid unexpected changes in behaviour
This changes also adds a migration to update existing projects and also removes `module` from the Universal tsconfig as per #17352 to enable lazy loading on the server.
It seems that this is causing issues with proxy config and IIS with Windows authentication, for now we remove the `ArchitectPlugin` since it's not being used.
Fixes#14595