1384 Commits

Author SHA1 Message Date
Alan Agius
0a406e8dd0 refactor(@angular-devkit/build-angular) remove _loadTslint method 2020-09-28 15:34:56 +02:00
Alan Agius
96bee9c6a5 refactor(@angular-devkit/build-angular): remove redundant tslint version check
Tslint has been added as an optional peer dependency which makes this check unnecessary since the package manager will issue a warning when an incorrect version is installed.
2020-09-28 15:34:56 +02:00
Alan Agius
1c4d358b38 fix(@angular-devkit/build-angular): implement relative method in extractor FS
This will be needed when the changes in angular/angular#39006 is merged.
2020-09-28 13:58:31 +02:00
Dmitriy Shekhovtsov
92f3889f98 fix(@angular-devkit/build-angular): maxModules were deprecated and renamed to modulesSpace 2020-09-28 13:57:38 +02:00
Dmitriy Shekhovtsov
eb8872aeee fix(@angular-devkit/build-angular): webpack5 deprecation of module property in Dependency 2020-09-28 11:23:41 +02:00
Charles Lyding
1873f2d28f fix(@angular-devkit/build-angular): add tslint as an optional peer dependency
tslint is currently used by the tslint builder within this package but is not represented in the dependencies. The can lead to accidental version mismatches as well as package manager hoisting problems due to the package manager not knowing the full dependency set of the package.
2020-09-25 23:10:56 +02:00
Charles Lyding
7fed4cf7f7 style(@angular-devkit/build-angular): remove unneeded no-implicit-dependencies rule disabling 2020-09-25 23:10:56 +02:00
Charles Lyding
ac9db989b8 fix(@angular-devkit/build-angular): add protractor as an optional peer dependency
protractor is currently used by the protractor builder within this package but is not represented in the dependencies. The can lead to accidental version mismatches as well as package manager hoisting problems due to the package manager not knowing the full dependency set of the package.
2020-09-25 23:10:56 +02:00
Charles Lyding
5bbac0774f fix(@angular-devkit/build-angular): add karma as an optional peer dependency
karma is currently used by the karma builder within this package but is not represented in the dependencies.  The can lead to accidental version mismatches as well as package manager hoisting problems due to the package manager not knowing the full dependency set of the package.
2020-09-25 23:10:56 +02:00
Charles Lyding
cdb404bd3c fix(@angular-devkit/build-angular): warn if using unsupported IE9/10 browsers
As of Angular v11, IE9 and IE10 are no longer officially supported.  A warning will now be shown during builds if these browsers are requested in the project's browserslist configuration.
2020-09-25 22:46:04 +02:00
Charles Lyding
0c112e5d91 feat(@angular-devkit/build-angular): support package references in styles & scripts options
The browser builder's `styles` and `scripts` options now support using a package name in the path when specifying a style or script.  This removes the need to use a relative path to the node modules directory in these options.  This provides support for Yarn PnP as well as reducing the complexity of the options especially for monorepo setups.  Relatively located files will take precedence over packages if they exist.  This precedence provides backwards compatibility with existing configurations.

Before :
`"styles": ["../node_modules/bootstrap/dist/css/bootstrap.css"]`

After:
`"styles": ["bootstrap/dist/css/bootstrap.css"]`
2020-09-25 20:22:04 +02:00
Alan Agius
dbdd3fc857 feat(@angular-devkit/build-angular): out of the box hot module replacement (HMR)
With this change we configure HMR internally and therefore users which want to use basic HMR functionality will not longer be required to change their application code.

This is important because previously a lot of users missed out on HMR or reported a broken behaviour. This also gives novice users a better chance to appreciate HMR and Angular because of the zero effort required to use HMR.

Closes #17324
2020-09-25 20:21:33 +02:00
Alan Agius
64f340d93f feat(@angular-devkit/build-angular): extract i18n messages from libraries
Closes #18871
2020-09-25 17:59:21 +02:00
Renovate Bot
cb2b308c8e build: update rollup to version 2.28.2 2020-09-25 13:41:50 +02:00
Charles Lyding
93e2438954 test(@angular-devkit/build-angular): test Ivy specific files in unused file tests
The test was previously run only in Ivy mode but with VE specific test case files.  The test now also enables strict templates to ensure template type checking files are properly excluded.
2020-09-24 14:30:15 +02:00
Alan Agius
b9c98ee5f1 fix(@angular-devkit/build-angular): add missing defaults to optimization property 2020-09-24 14:27:25 +02:00
Joey Perrott
25aa2d5929 refactor: remove usages of the term whitelist 2020-09-24 00:07:10 +03:00
Alan Agius
ce17094e0e refactor(@angular-devkit/build-angular): lazy require speed-measure-webpack-plugin 2020-09-23 11:22:58 -05:00
Alan Agius
ee14ab0193 refactor(@angular-devkit/build-angular): use optional chaining operator where possible in browser builder 2020-09-23 11:22:58 -05:00
Alan Agius
a73c947205 refactor(@angular-devkit/build-angular): use architect builder output error instead of logger 2020-09-23 11:22:58 -05:00
Alan Agius
76557029a9 style: add proper indentation to RXJS pipe operators 2020-09-23 11:22:58 -05:00
Alan Agius
11c6abdd79 refactor(@angular-devkit/build-angular): clean up differential loading config generation
Closes #16098
2020-09-23 11:22:58 -05:00
Alan Agius
f10f910ec9 refactor(@angular-devkit/build-angular): remove esVersionInFileName build option
This option can be determined via `wco.differentialLoadingMode`
2020-09-23 11:22:58 -05:00
Alan Agius
33f5b60069 refactor(@angular-devkit/build-angular): remove target parameter from BuildBrowserFeatures ctor 2020-09-23 11:22:58 -05:00
Alan Agius
8d770ed0db test: remove test which is no longer relevent
We removed webpack specific build logs from the CLI, therefore this test is no longer relevant.
2020-09-22 10:29:53 -05:00
Alan Agius
d3ad09508f refactor(@angular-devkit/architect): remove deprecated TestLogger
BREAKING CHANGE:

Deprecated `TestLogger` has been removed. Use `logging` API from `'@angular-devkit/core'` instead.

**Note:** this change doesn't effect application developers.
2020-09-22 10:29:53 -05:00
Renovate Bot
ab9968d76e build: update rollup to version 2.28.1 2020-09-22 10:29:35 -05:00
Renovate Bot
5e43259ded build: update terser-webpack-plugin to version 4.2.2 2020-09-21 11:56:12 -05:00
Renovate Bot
4261bdbf9d build: update copy-webpack-plugin to version 6.1.1 2020-09-21 11:55:56 -05:00
Charles Lyding
e5266fdd44 refactor(@angular-devkit/build-angular): temporarily disable Webpack 5 license extraction
The license extraction plugin is currently causing errors when building/serving with Webpack 5.  This change temporarily disables the option when Webpack 5 is used until further investigation can take place and to unblock initial Webpack 5 support.
2020-09-21 11:55:11 -05:00
Charles Lyding
ea2b19cedc refactor(@angular-devkit/build-angular): adjust Webpack configuration based on version 4/5
This change adds helpers to allow the Webpack configuration to be automatically adjusted based on the Webpack version in use.
These helpers are then used to provide configuration compatibility for Webpack 5 which has several differences to the Webpack 4 configuration.
Behavior is maintained between the two versions so that external option behavior is not altered.
2020-09-21 11:55:11 -05:00
Renovate Bot
4781b9245e build: update webpack to version 4.44.2 2020-09-18 14:55:08 -05:00
Renovate Bot
44887a87e6 build: update terser to version 5.3.2 2020-09-18 14:54:51 -05:00
Renovate Bot
83ffaee7db build: update sass to version 1.26.11 2020-09-18 14:53:57 -05:00
Alan Agius
99210b203d fix(@angular-devkit/build-angular): add node-sass deprecation warning 2020-09-18 14:53:31 -05:00
Renovate Bot
d077afde93 build: update rollup to version 2.27.1 2020-09-18 14:53:17 -05:00
Alan Agius
5996896076 feat(@angular-devkit/build-angular): improve build stats output format
With this change we also remove sourcemaps from build info to align with Webpack 5 output.
2020-09-18 14:52:38 -05:00
Alan Agius
13b17baebe refactor(@angular-devkit/build-angular): add spinners for localize and downlevelling 2020-09-16 10:38:58 -04:00
Renovate Bot
976cea459b build: update postcss-loader to version 4.0.2 2020-09-16 07:13:49 -04:00
Renovate Bot
25a3f453af build: update terser-webpack-plugin to version 4.2.1 2020-09-16 07:13:14 -04:00
Renovate Bot
0235cb0a89 build: update rollup to version 2.27.0 2020-09-16 07:11:37 -04:00
Alan Agius
0d10de5cbb refactor(@angular-devkit/build-angular): re-structure folder structure and move code
Previous
```
packages/angular_devkit/build_angular
├── plugins
│   └── webpack
└── src
    ├── angular-cli-files
    │   ├── models
    │   │   └── webpack-configs
    │   ├── plugins
    │   └── utilities
    │       ├── index-file
    │       └── service-worker
    ├── app-shell
    ├── browser
    │   └── specs
    ├── dev-server
    ├── extract-i18n
    ├── karma
    ├── ng-packagr
    ├── protractor
    ├── server
    ├── tslint
    ├── utils
    └── webpack
        └── models
```

Now
```
packages/angular_devkit/build_angular
├── plugins
└── src
    ├── app-shell
    ├── browser
    │   └── specs
    ├── dev-server
    ├── extract-i18n
    ├── karma
    ├── ng-packagr
    ├── protractor
    ├── server
    ├── tslint
    ├── utils
    │   └── index-file
    └── webpack
        ├── configs
        ├── plugins
        └── utils
```
2020-09-14 16:40:39 -04:00
Charles Lyding
9144cf87ff refactor(@angular-devkit/build-angular): support Webpack 5 errors/warnings
Webpack 5 uses an object to represent errors and warnings unlike Webpack 4 which used a string.  This change provides support for both scenarios.
2020-09-14 15:54:30 -04:00
Renovate Bot
54f296ca00 build: update mini-css-extract-plugin to version 0.11.2 2020-09-13 20:04:16 -04:00
Renovate Bot
118f698524 build: update terser-webpack-plugin to version 4.2.0 2020-09-12 09:42:10 -04:00
Alan Agius
14d70d15b9 refactor(@angular-devkit/build-angular): add missing formatOptions which is non optional in v11.0.0-next.1
Related to https://github.com/angular/angular/pull/38787
2020-09-11 14:31:07 -04:00
Renovate Bot
79f13bddb2 build: update terser to version 5.3.1 2020-09-11 07:31:58 -04:00
Alan Agius
622d08447d refactor: use ansi-colors instead of removed terminal utils 2020-09-10 20:19:33 +02:00
Charles Lyding
f31f853de8 refactor(@angular-devkit/build-angular): use Webpack ChunkGraph API in SuppressExtractedTextChunksWebpackPlugin 2020-09-10 19:46:45 +02:00
Alan Agius
9087197e4a fix(@angular-devkit/build-angular): set logging level to verbose when using --verbose 2020-09-10 17:53:02 +02:00