915 Commits

Author SHA1 Message Date
Alan Agius
82c438bedb refactor(@schematics/angular): clean up web-worker schematic
Remove code that used to handle version 8 applications. These should have migrated to the new structure when using ng-update.
2021-06-08 18:05:19 +02:00
Santosh Mahto
d13a866104 fix(@schematics/angular): working with formatting 2021-06-07 08:52:55 +02:00
Santosh Mahto
052b8fa4db fix(@schematics/angular): added webWorkerTsConfig into test option 2021-06-07 08:52:55 +02:00
Doug Parker
8690ed0a35 release: v12.1.0-next.4 2021-06-02 11:52:42 -07:00
Alan Agius
7cd801eb06 fix(@schematics/angular): show better error when non existing project is passed to the component schematic
Closes: #21003
2021-06-02 09:15:17 +02:00
Alan Agius
afc9d10688 fix(@schematics/angular): make version 12 workspace config migration idempotent
With this change we ensure that `update-angular-config-v12` migration is idempotent

Closes #20979
2021-05-31 12:49:24 +01:00
Doug Parker
2f295963d7 release: v12.1.0-next.3 2021-05-26 12:05:16 -07:00
Doug Parker
f0dd794f75 Revert "release: v12.1.0-next.3"
This reverts commit 8b967fabd95f66fcedb2903cc7a4ffff8a0fd43e.

Needed to update the version in `package.json` but didn't.
2021-05-26 11:50:48 -07:00
Doug Parker
8b967fabd9 release: v12.1.0-next.3 2021-05-26 11:39:21 -07:00
Joey Perrott
1ac3931d3e release: v12.1.0-next.2 2021-05-19 12:29:28 -07:00
Alan Agius
1080a52c96 fix(@schematics/angular): add migration to remove skipTests from @schematics/angular:module
Migration for #20842

Closes #20848
2021-05-19 17:28:14 +02:00
Pankaj Patil
36b5040cc4 fix(@schematics/angular): don't add skipTest option to module schematic options
Closes ##20811
2021-05-19 10:50:14 +02:00
Keen Yee Liau
74be7280ce docs(@schematics/angular): clarify that users need to install ng e2e builder
This commit adds a sentence to clarify that users need to install a `ng e2e`
builder when invoking the command for the first time.
2021-05-14 08:30:04 +02:00
Alan Cohen
ff752951b0 fix(@schematics/angular): remove --prod option from README template
Angular 12 defaults `ng build` to use `--production configuration` (formerly `--prod`)
2021-05-14 07:36:34 +02:00
Alan Agius
4ed1c4f42d fix(@schematics/angular): replace clientProject with project 2021-05-05 11:49:22 -04:00
Alan Agius
586226a305 fix(@angular/cli): infer schematic defaults correctly when using --project
Previously, the `--project` flag was ignored when gathering and merging the schematics defaults from the angular workspace configuration file.

Closes #20666
2021-05-05 11:49:22 -04:00
Alan Agius
7521a8727c fix(@schematics/angular): only run emitDecoratorMetadata removal migration in safe workspaces
Removal of `emitDecoratorMetadata` might cause runtime errors on projects which don't use the Angular Compiler to compile TypeScript code and therefore dependent on Decorators metadata during runtime.  One such example of these builders is `@nrwl/jest`.
2021-05-04 10:33:58 -04:00
Alan Agius
e992c9a70b build: update files to be fix eslint header/header failures 2021-05-04 09:59:40 -04:00
Sam Bulatov
1b9577af4a fix(@schematics/angular): add "type" option in enum schematic
closes: #20667
2021-05-03 10:43:07 -04:00
Charles Lyding
c1512e4274 build: update files to be eslint compliant
All TypeScript files have been updated to pass the new eslint-based linting checks. eslint compatible disabling comments have also been added in place of the previous tslint comments.
2021-05-03 07:31:02 -04:00
Charles Lyding
37a06a7c37 build: format all files
All files are now formatted using the ng-dev tools via prettier.
2021-04-28 16:05:49 -07:00
Alan Agius
decaef592e fix(@schematics/angular): fix migration for namedChunks and option
Both values of  `extractLicenses` and `namedChunks` were inverted.
2021-04-28 16:37:19 +02:00
Billy Lando
30815248a8 fix(@schematics/angular): avoid unuse imports for canLoad guard generation 2021-04-28 14:07:32 +02:00
Joey Perrott
003854257c build: migrate all file header to use Google LLC rather than Google Inc 2021-04-27 08:35:22 +02:00
Santosh Yadav
27bab2a66f fix(@schematics/angular): remove lint command from package.json
Angular 12 does not provide the default linter but CLI adds the ng lint
this PR removes the ng lint from new app created

Fixes #20618
2021-04-25 10:21:16 +02:00
Alan Agius
4c8e03256f fix(@angular-devkit/build-angular): remove left-over forkTypeChecker option 2021-04-22 15:40:36 +02:00
cexbrayat
26ec477262 fix(@schematics/angular): remove Protractor from home page 2021-04-22 10:57:10 +02:00
cexbrayat
29cf8125ca fix(@schematics/angular): remove jasmine-spec-reporter and ts-node from default workspace
The dependencies are only needed for protractor tests, so they should only be added by the e2e schematics.
2021-04-22 10:56:36 +02:00
Alan Agius
3d30e89c61 docs(@schematics/angular): remove hidden schematics from readme
Universal and E2E schematics are hidden/private.
2021-04-21 12:44:03 -07:00
Alan Agius
0272fc55b6 refactor(@schematics/angular): remove stylus from style options
BREAKING CHANGE:

`styl` (Stylus) is no longer a supported value as `style` in `application`, `component`, `ng-new` schematics. Stylus is not actively maintained and only 0.3% of the Angular CLI users use it.
2021-04-21 12:39:18 -07:00
Alan Agius
0a74d0d28d fix(@angular-devkit/build-angular): change several builder options defaults
BREAKING CHANGE:

A number of browser and server builder options have had their default values changed. The aim of these changes is to reduce the configuration complexity and support the new "production builds by default" initiative.

**Browser builder**
| Option                                 | Previous default value    | New default value |
|----------------------------------------|---------------------------|-------------------|
| optimization                           | false                     | true              |
| aot                                    | false                     | true              |
| buildOptimizer                         | false                     | true              |
| sourceMap                              | true                      | false             |
| extractLicenses                        | false                     | true              |
| namedChunks                            | true                      | false             |
| vendorChunk                            | true                      | false             |

**Server builder**
| Option        | Previous default value | New default value |
|---------------|------------------------|-------------------|
| optimization  | false                  | true              |
| sourceMap     | true                   | false             |
2021-04-21 12:39:01 -07:00
Keen Yee Liau
49ba5e20aa refactor(@schematics/angular): Do not include Protractor test in new project
Do not include Protractor for new projects since we do not have a concrete
plan for Protractor yet.
2021-04-21 12:38:46 -07:00
Keen Yee Liau
c3cc50e6b9 refactor(@schematics/angular): read build-angular's version from package.json
Now that `@angular-devkit/build-angular` is promoted to stable
(https://github.com/angular/angular-cli/pull/20528), it will
always have the same version as `@schematics/angular`.

With this change, there is no need to manually update `DevkitBuildAngular`
field in `latest-versions.ts` anymore.
2021-04-20 09:33:36 -05:00
Keen Yee Liau
5a57fea36b docs(@schematics/angular): add README and update description in schema
Create README for the package, and add missing description in some schema.
2021-04-19 20:34:35 +02:00
Charles Lyding
18c8adf0dc fix(@schematics/angular): set inlineStyleLanguage for universal if present in build options
The `inlineStyleLanguage` option should be set for an application's server target if also present in the application's build target. The setting is needed to ensure the server target properly builds the applica
tion's styles.
2021-04-19 20:30:35 +02:00
Charles Lyding
fdf41b24dc fix(@schematics/angular): set inlineStyleLanguage when application style option is used
The `style` option for the application schematic specifies the language/preprocessor to use for the application's external style files and should also setup the default for inline styles as well via the `inlineStyleLanguage` build option. The value can be adjusted after application generation if needed.
2021-04-19 20:30:35 +02:00
Alan Agius
e1bb8c4f9a build: update master version to 12.1.0-next.0 2021-04-19 20:25:36 +02:00
Keen Yee Liau
1a8ed40db8 build: bump version to v12.0.0-rc.0 2021-04-19 19:39:13 +02:00
Keen Yee Liau
c7a7a7591b release: v12.0.0-next.9 2021-04-14 16:47:18 -07:00
Charles Lyding
e33a3061f0 feat(@schematics/angular): migrate web workers to support Webpack 5
Webpack 5 now includes web worker support. However, the structure of the URL within the `Worker` constructor must be in a specific format.
A migration has been added for Angular v12 that will convert web workers from the old structure to the new structure.
Before: `new Worker('./app.worker', ...)`
After: `new Worker(new URL('./app.worker', import.meta.url), ...)`
2021-04-14 19:34:21 -04:00
Alan Agius
36a8882ab3 refactor(@schematics/angular): remove migration of non LTS versions
With this change we remove migrations for non LTS version of Angular CLI.
2021-04-14 17:20:33 -04:00
Alan Agius
d7bedb7293 build: promote @angular-devkit/build-angular to stable 2021-04-14 15:50:27 -04:00
Alan Agius
076ab0f11f refactor: add correct schema keys
With this change
- We replace `id` with `$id`,  this no longer valid in draft-07.
- Replace all `$schemas` to `http://json-schema.org/draft-07/schema`, this is needed to "pin" the schema to `draft-07`.

More information about `draft-07` can be found https://json-schema.org/draft-07/json-schema-release-notes.html
2021-04-13 10:51:12 -04:00
Alan Agius
84e0231208 feat(@schematics/angular): update jasmine-spec-reporter to version 7 2021-04-12 05:51:39 -04:00
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
Charles Lyding
df988c2493 fix(@schematics/angular): update web-worker to support Webpack 5
Webpack 5 now includes web worker support. However, the structure of the URL within the `Worker` constructor must be in a specific format.
Before: `new Worker('./app.worker', ...)`
After: `new Worker(new URL('./app.worker', import.meta.url), ...)`
2021-04-08 09:42:47 -04:00
Doug Parker
3693153c66 build: bump version to v12.0.0-next.8 2021-04-07 16:14:21 -07:00
Doug Parker
ad60469444 release: v12.0.0-next.8 2021-04-07 12:33:29 -07:00
Alan Agius
645353db26 fix(@schematics/angular): run update-i18n migration for server builder 2021-04-03 14:45:58 +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