577 Commits

Author SHA1 Message Date
Alan Agius
94ada4f6b8 docs(@angular/cli): use application instead of app 2020-11-02 13:36:13 -06:00
Charles Lyding
5db4ec7df7 refactor(@angular/cli): remove outdated workspace targets warning
The stable workspace API will now normalize configuration file content.
2020-10-30 10:17:49 -05:00
Charles Lyding
7cbc72e16f refactor(@angular/cli): use jsonc-parser for JSON configuration parsing 2020-10-30 10:17:49 -05:00
Charles Lyding
0a02ea55bb refactor(@angular/cli): remove NodeJsSyncHost from config utilities 2020-10-30 10:17:49 -05:00
Alan Agius
a75478a45b docs(@angular-devkit/build-angular): remove ="true" from prod flag in ng build documentation 2020-10-26 14:24:41 -04:00
Charles Lyding
cc723d8d74 feat(@angular-devkit/build-angular): support following symlinked asset directories
By default subdirectories within a symlinked directory are not searched by a glob.  The new `followSymlinks` option for the longhand form of the `assets` browser builder option now allows opting in to search such subdirectories.
2020-10-21 22:03:24 +02:00
Charles Lyding
13f375d199 fix(@angular/cli): use newer update command if global version is newer
This allows improvements and bugfixes in later versions of the update command to be used in projects with older versions of the Angular CLI that do not have bootstrapping (<8.3.13).
2020-10-21 17:10:48 +02:00
Charles Lyding
fd63e29406 fix(@angular/cli): coerce prompt answers to requested property types
This change converts answers from prompts into the property type requested from the schema.  This allows properties that expect a number to correctly validate when an input prompt is used.
2020-10-21 16:37:11 +02:00
Alan Agius
47373010e2 refactor(@angular/cli): rename ng xi18n to ng extract-i18n
`ng i18n-extract` and `ng xi18n` has been deprecated in favor of `ng extract-i18n` to have a better intuitive naming and match the architect key in `angular.json`.
2020-10-21 16:33:59 +02:00
Alan Agius
5f930c984b docs: remove =true from --next
`=true` us redundant
2020-10-21 15:05:32 +02:00
Charles Lyding
37686b684e fix(@angular/cli): skip searching deprecated packages with ng add
When attempting to add a package via the add command, packages that have been marked as deprecated will no longer be installed when the deprecated package's peer dependencies match the project's dependencies.
2020-10-20 18:48:00 +02:00
Alan Agius
a09a2e4056 fix(@angular/cli): include deprecated option in JSON help
This option is used to mark deprecated options as such in AIO.
2020-10-20 16:54:05 +02:00
Alan Agius
2298ab865b refactor(@angular-devkit/build-angular): remove deprecated browser build option rebaseRootRelativeCssUrls
BREAKING CHANGE:

Deprecated `rebaseRootRelativeCssUrls` browser builder option has been removed without replacement. This option was used to change root relative URLs in stylesheets to include base HREF and deploy URL and was used only for compatibility and transition as this behavior is non-standard.
2020-10-20 16:53:24 +02:00
Renovate Bot
3905033d17 build: update resolve to version 1.18.1 2020-10-20 09:15:37 +02:00
Alan Agius
ea1325e03e docs(@angular/cli): fix formatting in docs command 2020-10-20 08:51:02 +02:00
Alan Agius
212374a5f1 refactor(@angular/cli): remove install-package under utils
Remove the lone `install-package.ts` file from tasks to utilities
2020-10-19 19:28:13 +02:00
Alan Agius
7c274bf31f fix(@angular/cli): add missing dev-server headers option in IDE schema 2020-10-15 18:30:24 +02:00
Alan Agius
871dd6a434 feat(@angular-devkit/build-angular): enable font inlining optimizations
With this change we inline Google fonts and icons in the index html file when optimization is enabled.

**Before**
```html
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
```
**After**
```html
<style>
  @font-face {
    font-family: 'Material Icons';
    font-style: normal;
    font-weight: 400;
    src: url(https://fonts.gstatic.com/s/materialicons/v55/flUhRq6tzZclQEJ-Vdg-IuiaDsNcIhQ8tQ.woff2) format('woff2');
  }

  .material-icons {
    font-family: 'Material Icons';
    font-weight: normal;
    font-style: normal;
    font-size: 24px;
    line-height: 1;
    letter-spacing: normal;
    text-transform: none;
    display: inline-block;
    white-space: nowrap;
    word-wrap: normal;
    direction: ltr;
  }
</style>
```

To opt-out of this feature set `optimization.fonts: false` or `optimization.fonts.inline: false` in the browser builder options.

Example:
```js
"configurations": {
  "production": {
    "fileReplacements": [
      {
        "replace": "src/environments/environment.ts",
        "with": "src/environments/environment.prod.ts"
      }
    ],
    "optimization": {
      "fonts": false
    },
```

More information about the motivation for this feature can be found: https://github.com/angular/angular-cli/issues/18730

Note: internet access is required during the build for this optimization to work.
2020-10-14 21:57:29 +03:00
Alan Agius
4e22443321 refactor(@angular/cli): clean up getProjectDependencies and add return types 2020-10-14 10:07:39 -04:00
Alan Agius
a8b8b5f7ae fix(@angular/cli): resolve packages package.json from workspace directory
Unlike `require.resolve`, the `resolve` package `paths` is only used as a fallback when the package is not resolved from the `basedir`,

Previously this resulted in the temporary version of CLI being resolved here which resulted in `ng update` incorrectly stating that there are no updates.
2020-10-14 10:07:39 -04:00
Renovate Bot
0b289575b0 build: update npm-package-arg to version 8.1.0 2020-10-13 12:48:07 -04:00
Alan Agius
2960bf08b2 refactor(@angular/cli): remove redundant context transform 2020-10-13 12:47:06 -04:00
Alan Agius
5318e4c511 fix(@angular/cli): don't display prompts twice
Closes #19027
2020-10-13 12:37:59 -04:00
Alan Agius
49199cee5d fix(@angular/cli): don't show deprecation messages for defaults when using --defaults
With this change we use the addUndefinedDefaults transformer post validation and don't create prompts which have a default value when options.defaults is truthy.

Closes: #18692
2020-10-13 12:36:48 -04:00
Alan Agius
90988aaf52 fix(@angular/cli): collect analytics option usage from workspace config and prompts
With this change we fix two analytics collection bugs:
- We now collect the usage of options defined in the workspace config (angular.json).
- We now also collect values set via schematic prompts.

Closes: #17900
2020-10-07 09:54:59 -04:00
Renovate Bot
04b867f3d3 build: update uuid to version 8.3.1 2020-10-04 16:50:26 -04:00
Drummond Dawson
7254d18ccb fix(@angular/cli): add blank line in migration commit message
Adds a blank line in the commit message between the subject and body in order to properly separate the two.
2020-10-04 16:50:00 -04:00
Charles Lyding
d903d39fc8 refactor(@angular/cli): use new NodeWorkflow schematic features
This change reduces the amount of schematic runtime setup code by leveraging the new options for the root path and schema validation in the NodeWorkflow class.
2020-10-02 18:56:11 -04:00
Charles Lyding
b2b536789b refactor(@angular/cli): discover/load workspace on startup
Previously, the workspace configuration file was found and loaded by individual commands potentially multiple times.  This change moves the initial workspace location discovery and loading of the workspace to the CLI startup.  It also provides the workspace to each command so that the commands can reuse the already loaded and parsed workspace configuration.
2020-10-02 07:53:07 -04:00
Renovate Bot
b9c5670dae build: update symbol-observable to version 2.0.3 2020-10-01 08:44:21 -04:00
Alan Agius
e96fbd3c8a refactor(@angular-devkit/build-angular): change errors and warnings messages
Sometimes the WARNING IN/ERROR IN can lead of ambiguous messages

 - Use `Warning` instead of `WARNING IN`
-  Use `Error` instead of `Error In`
2020-09-30 16:17:05 +02:00
Alan Agius
8e38cec283 refactor(@angular/cli): remove deprecated karma builder environment schema option 2020-09-30 13:49:13 +02:00
Renovate Bot
efb97c87f0 build: update symbol-observable to version 2.0.2 2020-09-30 09:08:54 +02:00
Alan Agius
824add1778 fix(@angular/cli): no-op ng update --all
'--all' functionality has been removed from `ng update` as updating multiple packages at once is not recommended. To update the depencencies in your workspace 'package.json' use the update command of your package manager.

Closes #15278
Closes #13095
Closes #12261
Closes #12243
Closes #18813
2020-09-29 16:48:51 +02:00
Renovate Bot
c5ddca96f8 build: update open to version 7.3.0 2020-09-29 13:52:22 +02:00
Alan Agius
b555c6aa45 fix(@angular/cli): 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
88c3acb945 fix(@angular/cli): favor dirname when resolving @schematics/angular
This ensures that the correct build-in version of `@schematics/angular` is resolved.

Closes #18840
2020-09-24 00:05:58 +03:00
Jefiozie
432fcb0d9b fix(@angular/cli): replace regex with correct project name validation
Closes #17579
2020-09-24 00:04:58 +03:00
Charles Lyding
92f2559dbb refactor(@angular/cli): remove outdated 1.x karma plugin error placeholder
For Angular 6, an error inducing file was introduced in the 1.x location of the karma plugin for the Angular CLI.  This was useful during the 1.x -> 6 transition to assist users to migrate with a helpful error message.  Now that 1.x and 6 are no longer supported, this can be removed.
2020-09-22 10:30:21 -05:00
Renovate Bot
ee37b4bb2d build: update debug to version 4.2.0 2020-09-21 11:56:04 -05:00
Alan Agius
64cc005f0b refactor: change UPDATE action color to cyan 2020-09-14 16:36:30 -04:00
Alan Agius
a21eb1588e fix(@angular/cli): improve logs in ng update
These addresses;
- When a large number of migration are executed, it's hard to differentiate between the title and description.
- Fix alignments of logs
2020-09-14 16:36:30 -04:00
Charles Lyding
b6ea1ab15e fix(@angular/cli): remove version command node module assumptions
This change removes all direct usage of the `node_modules` directory from the version command.  This provides improved support for yarn PnP as well as prevents a crash when a workspace does not have a `node_modules` directory.

Fixes #10474
2020-09-14 07:23:55 -04:00
Keen Yee Liau
297fc923ab build: remove experimental build event protocol 2020-09-11 13:24:38 -04:00
Alan Agius
622d08447d refactor: use ansi-colors instead of removed terminal utils 2020-09-10 20:19:33 +02:00
Renovate Bot
2aa01ac2ca build: update symbol-observable to version 2.0.1 2020-09-05 11:59:41 +02:00
Andrei Alecu
d01d647431 refactor(@angular/cli): improve update package discovery 2020-09-03 18:21:06 +02:00
Charles Lyding
18fdb0139f refactor(@angular/cli): remove node module directory assumption during initialization
This also does some minor code cleanup to the version mismatch check logic which contained the node modules directory reference.
2020-09-03 08:35:40 +02:00
Renovate Bot
b5560ebebe build: update symbol-observable to version 2.0.0 2020-09-03 00:20:40 +03:00