1863 Commits

Author SHA1 Message Date
Alan Agius
695a01ba02 feat(@schematics/angular): configure new libraries to be published in Ivy partial mode
With this change we configure new libraries to be published using Ivy partial compilation instead of the deprecated View Engine rendering engine, we also remove several view engine specific `angularCompilerOptions`.

New libraries can be published using this format, as they are not depend upon by View Engine libraries or application.
2021-04-09 18:40:39 -04:00
Alan Agius
f145312666 fix(@angular-devkit/build-angular): update karma builder to use non-deprecated API
With this change we update the Karma builder to use the new Server API.

Closes: #20479
2021-04-09 13:36:07 -04:00
Renovate Bot
934753c330 build: update postcss-loader to version 5.2.0 2021-04-09 07:14:20 -04:00
Renovate Bot
6953391afb build: update css-loader to version 5.2.0 2021-04-09 07:13:36 -04:00
Charles Lyding
79f369c26f refactor(@angular-devkit/build-angular): optimize analytics plugin bundle stats for Webpack 5
Newer Webpack 5 APIs allow the bundle stat generation for analytics to be optimized including less iteration of chunks and assets.
2021-04-08 09:42:47 -04:00
Charles Lyding
43e22ae24a build: update webpack to version 5.30.0 2021-04-08 09:42:47 -04:00
Charles Lyding
d883ce5d7e feat(@angular-devkit/build-angular): upgrade to Webpack 5 throughout the build system
With this change Webpack 5 is now used by the Angular tooling to build applications. Webpack 4 usage and support has been removed.
No project level configuration changes are required to take advantage of the upgraded Webpack version when using the official Angular builders.
Custom builders based on this package that use the experimental programmatic APIs may need to be updated to become compatible with Webpack 5.

BREAKING CHANGE: Webpack 5 lazy loaded file name changes
Webpack 5 generates similar but differently named files for lazy loaded JavaScript files in development configurations (when the `namedChunks` option is enabled).
For the majority of users this change should have no effect on the application and/or build process. Production builds should also not be affected as the `namedChunks` option is disabled by default in production configurations.
However, if a project's post-build process makes assumptions as to the file names then adjustments may need to be made to account for the new naming paradigm.
Such post-build processes could include custom file transformations after the build, integration into service-side frameworks, or deployment procedures.
Example development file name change: `lazy-lazy-module.js` --> `src_app_lazy_lazy_module_ts.js`

BREAKING CHANGE: Webpack 5 web worker support
Webpack 5 now includes web worker support. However, the structure of the URL within the `Worker` constructor must be in a specific format that differs from the current requirement.
Web worker usage should be updated as shown below (where `./app.worker` should be replaced with the actual worker name):
Before: `new Worker('./app.worker', ...)`
After:  `new Worker(new URL('./app.worker', import.meta.url), ...)`
2021-04-08 09:42:47 -04:00
Renovate Bot
b7c77f6a86 build: update core-js to version 3.10.1 2021-04-08 08:35:10 -04:00
Renovate Bot
6ae3f8de49 build: update mini-css-extract-plugin to version 1.4.1 2021-04-08 08:31:57 -04:00
Charles Lyding
e607d4482e test(@angular-devkit/build-angular): increase bazel shards for dev-server tests
With recent improvements to the dev-server builder unit tests, additional parallel testing should now be possible.
The unused `express` dependencies are also removed.
2021-04-07 19:16:07 -04:00
Charles Lyding
a6d886d313 test(@angular-devkit/build-angular): use port 0 in dev-server builder tests
This change updates the remainder of the non-builder harness tests to use a random port when testing. This change reduces the frequency of test flakes as well as improves the opportunity for parallel test execution.
2021-04-07 10:29:49 +02:00
Charles Lyding
119256f72b test(@angular-devkit/build-angular): add dev-server builder port option tests
This change adds expanded unit tests for the dev-server builder's `port` option using the builder test harness.
2021-04-07 10:29:49 +02:00
Charles Lyding
c9a002c04b test(@angular-devkit/build-angular): add initial dev-server builder hmr and liveReload option tests
The CommonJS usage warning tests are moved to use the builder harness for both the `hmr` and `liveReload` options.
2021-04-07 10:29:49 +02:00
Renovate Bot
82386319dc build: update cssnano to version 4.1.11 2021-04-07 09:01:57 +02:00
Charles Lyding
8770d5f015 refactor(@angular-devkit/build-angular): remove use of deprecated ngtools ivy namespace export
With the removal of the deprecated ViewEngine-based Webpack plugin, the ivy namespace export that was previously used is now deprecated in favor of direct exports of the Ivy-based plugin.
2021-04-05 19:20:56 +02:00
Charles Lyding
8c9b2a2589 test(@angular-devkit/build-angular): remove unneeded custom Jasmine test timeouts
The default Jasmine test timeout is set to 2.5 minutes for all builder tests. The smaller timeouts (that are now removed from individual tests) can lead to test flakes especially on CI which can have large performance variability.
2021-04-04 09:07:06 +02:00
Charles Lyding
9f331e2772 test(@angular-devkit/build-angular): remove redundant browser assets unit test
These unit tests have been rewritten to use the builder test harness in the new test directory structure and can be removed.
2021-04-04 09:07:06 +02:00
Alan Agius
5cf9a08dc7 refactor(@angular-devkit/build-angular): remove deprecated i18n options from server and browser builder
BREAKING CHANGE:

Removal of deprecated browser and server command options.
- `i18nFile`,  use `locales` object in the project metadata instead.
- `i18nFormat`, No longer needed as the format will be determined automatically.
- `i18nLocale`, use `localize` option instead.
2021-04-03 14:45:58 +02:00
Renovate Bot
7d002213be build: update open to version 8.0.5 2021-04-03 13:22:44 +02:00
Charles Lyding
eca5a01f6e fix(@angular-devkit/build-angular): remove deprecated i18nLocale and i18nFormat options from i18n-extract
BREAKING CHANGE: Removal of deprecated `extract-i18n` command options
The deprecated `i18nLocale` option has been removed and the `i18n.sourceLocale` within a project's configuration should be used instead.
The deprecated `i18nFormat` option has been removed and the `format` option should be used instead.
2021-04-02 21:13:26 +02:00
Charles Lyding
677913fc38 fix(@angular-devkit/build-angular): remove usage of deprecated View Engine compiler
BREAKING CHANGE: Removal of View Engine support from application builds
With the removal of the deprecated View Engine compiler in Angular version 12 for applications, Ivy-based compilation will always be used when building an application.
The default behavior for applications is to use the Ivy compiler when building and no changes are required for these applications.
For applications that have opted-out of Ivy, a warning will be shown and an Ivy-based build will be attempted. If the build fails,
the application may need to be updated to become Ivy compatible.
2021-04-02 08:11:11 +02:00
Renovate Bot
e310a748dc build: update postcss-import to version 14.0.1 2021-04-02 08:08:47 +02:00
Renovate Bot
183528d1a3 build: update core-js to version 3.10.0 2021-03-31 10:06:00 -06:00
Renovate Bot
1907406ca4 build: update postcss to version 8.2.9 2021-03-31 10:05:33 -06:00
Alan Agius
fd2dbb37ca test(@angular-devkit/build-angular): clean up tests from ViewEngine code 2021-03-31 10:04:23 -06:00
Alan Agius
3d1bd01641 refactor(@angular-devkit/build-angular): remove ngfactories checks 2021-03-30 14:37:09 -06:00
Alan Agius
b35517505f refactor(@angular-devkit/build-angular): remove view engine check from analytics collector 2021-03-30 14:37:09 -06:00
Alan Agius
1c2aeeb46a refactor(@angular-devkit/build-angular): remove view engine app-shell generation
BREAKING CHANGE:  App-shell builder now only supports generation using Ivy
2021-03-30 14:37:09 -06:00
Alan Agius
27a41f2615 build: update to critters 0.0.10 2021-03-30 14:35:11 -06:00
Charles Lyding
012700ace5 fix(@angular-devkit/build-angular): remove deprecated View Engine support for i18n extraction
BREAKING CHANGE: Removal of View Engine support from i18n extraction
With the removal of the deprecated View Engine compiler in Angular version 12 for applications, the `ng extract-i18n` command will now always use the Ivy compiler.
The `--ivy` option has also been removed as Ivy-based extraction is always enabled.
The default behavior for applications is to use the Ivy compiler for building/extraction and no changes are required for these applications.
For applications that have opted-out of Ivy, a warning will be shown and Ivy-based extraction will be attempted. If the extraction fails,
the application may need to be updated to become Ivy compatible.
2021-03-30 14:34:52 -06:00
Charles Lyding
db4c6baf5a test(@angular-devkit/build-angular): add dev-server builder proxyConfig option tests
This change adds expanded unit tests for the dev-server builder's `proxyConfig` option using the builder test harness.
2021-03-30 14:33:49 -06:00
Charles Lyding
66f1b13eab test(@angular-devkit/build-angular): add dev-server builder servePath option tests
This change adds expanded unit tests for the dev-server builder's `servePath` option using the builder test harness.
2021-03-30 14:33:49 -06:00
Renovate Bot
c2c9a4169c build: update rxjs to version 6.6.7 2021-03-29 08:20:35 -06:00
Renovate Bot
480550b849 build: update mini-css-extract-plugin to version 1.4.0 2021-03-29 08:20:21 -06:00
Renovate Bot
e82f46cfbf build: update license-webpack-plugin to version 2.3.16 2021-03-29 08:20:00 -06:00
Renovate Bot
af47803a98 build: update @babel/core to version 7.13.13 2021-03-29 08:19:40 -06:00
Charles Lyding
649de5d016 test(@angular-devkit/build-angular): remove View Engine related unit tests
With the upcoming removal of View Engine support for applications in version 12, the View Engine related unit tests are no longer needed.
2021-03-29 08:18:39 -06:00
Alan Agius
51cb3181ea fix(@angular-devkit/build-angular): validate scripts and styles bundleName
Closes #20360
2021-03-29 08:17:49 -06:00
Charles Lyding
aeebd14f04 perf(@ngtools/webpack): only check affected files for Angular semantic diagnostics
This change improves the performance of incremental type checking of Angular templates by reducing the number of calls to retrieve the diagnostics.
Only the set of affected files will be queried on a rebuild. The affected set includes files TypeScript deems affected, files that
are required to be emitted by the Angular compiler, and the original file for any TTC shim file that TypeScript deems affected.
2021-03-29 08:16:36 -06:00
Renovate Bot
6a3a7b020b build: update semver to version 7.3.5 2021-03-24 09:48:08 -04:00
Renovate Bot
f6d9774559 build: update cacache to version 15.0.6 2021-03-23 12:11:30 -04:00
Renovate Bot
90536fd7f3 build: update babel packages 2021-03-23 12:07:03 -04:00
Charles Lyding
ac4c109beb fix(@angular-devkit/build-angular): ensure output directory is present before writing stats JSON
If an error occurs during a build, it is possible that the output path directory may not be present and then cause the stats JSON file write to fail.

Fixes: #20349
2021-03-22 15:41:41 -04:00
Alan Agius
6916bc912b build: update @types/babel__core to version 7.1.14 2021-03-22 09:11:41 -04:00
Renovate Bot
caafc6923e build: update open to version 8.0.4 2021-03-21 21:08:41 -04:00
Renovate Bot
0931e37f30 build: update open to version 8.0.3 2021-03-19 10:53:19 -04:00
Charles Lyding
5895105947 test(@angular-devkit/build-angular): reduce build time in browser builder watch test
This change removes application code during the test which is not needed for the watch option test.
2021-03-19 06:42:41 -04:00
Charles Lyding
2041c70f76 test(@angular-devkit/build-angular): add dev-server builder deployUrl behavior tests
This change adds expanded unit tests for the dev-server builder's build deploy URL behavior using the builder test harness.
2021-03-19 06:42:41 -04:00
Charles Lyding
352416fea8 test(@angular-devkit/build-angular): add dev-server builder publicHost option
This change adds expanded unit tests for the dev-server builder's `publicHost` option using the builder test harness.
2021-03-19 06:42:41 -04:00
Charles Lyding
888ac92127 test(@angular-devkit/build-angular): add dev-server builder disableHostCheck option
This change adds expanded unit tests for the dev-server builder's `disableHostCheck` option using the builder test harness.
2021-03-19 06:42:41 -04:00