1660 Commits

Author SHA1 Message Date
Charles Lyding
faf7b26ef9 test(@angular-devkit/build-angular): add browser builder option test for main 2020-12-18 10:37:26 +01:00
Charles Lyding
bfd91096be test(@angular-devkit/build-angular): add harness file jasmine helpers
This change adds an `expectFile` jasmine helper function that reduces the amount of code necessary to check a file's existence, size, or content.  Additional contextual information is also displayed when an expectation fails.
2020-12-18 10:37:26 +01:00
Charles Lyding
97bfd46b67 test(@angular-devkit/build-angular): use harness for browser builder works test
This converts the 'works' spec to use the new builder harness for testing. The change also provides for a before/after comparison of an existing test.
2020-12-18 10:37:26 +01:00
Charles Lyding
bcac38331e test(@angular-devkit/build-angular): add builder test harness 2020-12-18 10:37:26 +01:00
Charles Lyding
0e5dab45ef fix(@angular-devkit/build-angular): use URL rewrite in karma fallback middleware
This changes the internal Angular Karma plugin's asset fallback middleware to rewrite the request URL directly instead of trying to copy the request properties.  With changes in newer Node.js versions, not all request properties may be enumerable.

Fixes: #19644
2020-12-18 08:31:59 +01:00
Renovate Bot
8186c08c51 build: update babel packages 2020-12-17 20:07:25 +01:00
Renovate Bot
d7494c4d8d build: update webpack-merge to version 5.7.2 2020-12-16 15:50:20 +00:00
Renovate Bot
f58ec52b69 build: update postcss-import to version 14.0.0 2020-12-16 13:56:02 +00:00
Renovate Bot
3e4ce84312 build: update rollup to version 2.35.1 2020-12-16 13:55:17 +00:00
Renovate Bot
1bc5991785 build: update mini-css-extract-plugin to version 1.3.3 2020-12-16 13:55:08 +00:00
Renovate Bot
0dcdea91c0 build: update webpack-merge to version 5.7.0 2020-12-15 12:33:20 +00:00
Renovate Bot
bfe6103999 build: update source-map-loader to version 1.1.3 2020-12-15 12:32:53 +00:00
Renovate Bot
876ddd1848 build: update semver to version 7.3.4 2020-12-15 12:32:44 +00:00
Renovate Bot
c920df1594 build: update sass to version 1.30.0 2020-12-15 12:32:35 +00:00
Renovate Bot
89ee4c3066 build: update postcss to version 8.2.1 2020-12-15 12:31:55 +00:00
Renovate Bot
82f096f589 build: update license-webpack-plugin to version 2.3.2 2020-12-15 12:31:34 +00:00
Renovate Bot
1acbc15ac8 build: update less to version 3.13.0 2020-12-15 12:31:24 +00:00
Renovate Bot
611fb943a8 build: update autoprefixer to version 10.1.0 2020-12-15 12:30:59 +00:00
Alan Agius
ba9c755f33 fix(@angular-devkit/build-angular): add console error when using HMR in production mode
FIx: #19591
2020-12-15 12:25:15 +00:00
Alan Agius
e68c59a37c docs: update inline option description 2020-12-09 14:36:07 -05:00
Alan Agius
f0d18e990e docs: change sourcemap to source map
The latter is more in used in other articules such as:
-  https://developer.mozilla.org/en-US/docs/Tools/Debugger/How_to/Use_a_source_map
- https://developers.google.com/web/tools/chrome-devtools/javascript/source-maps
2020-12-09 14:36:07 -05:00
Keen Yee Liau
48a278e18f fix(@angular-devkit/build-angular): identify plugin provided as string
Karma plugins could be provided either a string or object, but our detection
logic for code coverage plugin only covers the string case.

Fix #19571
2020-12-09 09:52:57 -05:00
Charles Lyding
c94a1961fc fix(@angular-devkit/build-angular): define forwardRef as a pure function
By configuring the optimizer (`terser`) to be aware that the Angular `forwardRef` helper function is a pure function, the optimizer can completely remove the helper call when the return value is unused.
2020-12-08 19:54:14 -05:00
Alan Agius
d3afdcc1b3 fix(@angular-devkit/build-angular): add file path in CSS optimization exception
Closes #19561
2020-12-08 14:39:36 -05:00
Alan Agius
ca69c8c6b4 fix(@angular-devkit/build-angular): update ScriptsWebpackPlugin to work with Webpack 5
Closes: #19550
2020-12-07 15:23:29 -05:00
Renovate Bot
30b8e00f2a build: update core-js to version 3.8.1 2020-12-07 13:11:25 -05:00
Alan Agius
eb30a92e8a feat(@angular-devkit/build-angular): enable inlining of critical CSS optimizations
This is another feature that we mentioned in the Eliminate Render Blocking Requests RFC (#18730)

Inlining of critical CSS is turned off by default. To opt-in this feature set `inlineCritical` to `true`.

Example:
```json
"configurations": {
  "production": {
    "fileReplacements": [
      {
        "replace": "src/environments/environment.ts",
        "with": "src/environments/environment.prod.ts"
      }
    ],
    "optimization": {
      "styles": {
        "minify": true,
        "inlineCritical": true,
       }
    },
```

To learn more about critical CSS see;
https://web.dev/defer-non-critical-css
https://web.dev/extract-critical-css/

In a future version of the Angular CLI `inlineCritical` will be enabled by default.

Closes: #17966
Closes: #11395
Closes: #19445
2020-12-04 15:41:29 -05:00
Alan Agius
ee6bb1359f docs: fix elimination typo 2020-12-04 13:42:26 -05:00
Charles Lyding
8d92a7cbf0 feat(@angular-devkit/build-angular): support using TypeScript 4.1 2020-12-03 16:43:39 -05:00
Alan Agius
227804fd6e fix(@angular-devkit/build-angular): stylus not resolving imports from libraries
- Adds usage of webpackImporter https://www.npmjs.com/package/stylus-loader#webpackimporter
- Removes resolve-url-loader usage since stylus handles resolve paths https://stylus-lang.com/docs/js.html#stylusresolveroptions

Closes #19524
2020-12-03 12:59:08 -05:00
Alan Agius
a46bad4e31 fix(@angular-devkit/build-angular): fix termination of process when using CTRL+C
Closes #19531
2020-12-03 12:58:49 -05:00
Alan Agius
6fe8a6338d fix(@angular-devkit/build-angular): update index html webpack plugin to use non deprecated Webpack 5 API 2020-12-03 10:42:09 -05:00
Alan Agius
b546d798bc docs: add description to localize option 2020-11-30 19:04:21 +01:00
Alan Agius
064d62014c fix(@angular-devkit/build-angular): resolve partial SCSS files in sourcemaps
Closes #19505
2020-11-30 11:17:20 +01:00
Renovate Bot
c11faf7014 build: update rollup to version 2.34.0 2020-11-29 09:10:26 +01:00
Renovate Bot
b6cbcaa488 build: update autoprefixer to version 10.0.4 2020-11-29 09:07:45 +01:00
Renovate Bot
d416102b14 build: update terser to version 5.5.1 2020-11-28 09:27:01 +01:00
Renovate Bot
707e03f60d build: update babel-loader to version 8.2.2 2020-11-27 10:01:19 +01:00
Renovate Bot
7dc7063c37 build: update autoprefixer to version 10.0.3 2020-11-27 09:05:16 +01:00
Renovate Bot
1b2646a56b build: update core-js to version 3.8.0 2020-11-26 09:31:08 +01:00
Charles Lyding
f8b9fecf88 fix(@angular-devkit/build-angular): allow default Webpack 5 caching
With upstream fixes in place, the default Webpack 5 caching behavior can now be enabled.  In development mode, memory caching will now be used, and in production, caching will be disabled as per Webpack 5 default behavior.
2020-11-26 09:17:12 +01:00
Renovate Bot
def6029df8 build: update @babel/core to version 7.12.9 2020-11-26 09:16:54 +01:00
Alan Agius
9c57e45d4e docs: improve description for optimization, configuration and target options.
Closes #16572
Closes #17978
Closes https://github.com/angular/angular/issues/39780
2020-11-25 09:09:00 +00:00
Renovate Bot
35f40906fa build: update postcss to version 8.1.10 2020-11-25 09:06:32 +00:00
Alan Agius
d71ee210bf fix(@angular-devkit/build-angular): apply local libraries sourcemap without vendor: true
With this change we apply sourcemaps of libraries in a monorepo without the need to enable `vendor: true`. This is more intuitive behavior and  in line with what the users expect.

We also suppress the `Failed to parse source map from` in-actionable warning.

Closes #11305
2020-11-24 13:33:50 +00:00
Renovate Bot
be48d0ab68 build: update babel packages 2020-11-24 13:31:36 +00:00
Renovate Bot
ed087f988d build: update postcss to version 8.1.9 2020-11-23 10:22:37 +00:00
Charles Lyding
e96c1a9b46 fix(@angular-devkit/build-angular): update Angular peer dependencies to 11.1 prerelease 2020-11-23 10:21:31 +00:00
Renovate Bot
4f547513d9 build: update postcss-loader to version 4.1.0 2020-11-23 10:20:57 +00:00
Alan Agius
9908b59fd1 fix(@angular-devkit/build-angular): handle HTML file with no body and head tags
Closes #19426
2020-11-20 11:38:04 +00:00