Skip to content

Commit

Permalink
fix(@angular/cli): add engine field support for npm 8 and higher
Browse files Browse the repository at this point in the history
The `npm` package manager recently released version 8. This version removes support for older versions of Node.js but retains support for the versions that align with Angular's support range. The Angular CLI packages unfortunately did not support version 8 due to the ranges only permitting versions ^6.11.0 and ^7.5.6 which were the minimums for each that ensured a functioning Angular CLI environment. The range has now been expanded to include >=8.0.0 to allow newer versions of `npm` to function as well.

npm 8.0.0 release information: https://github.com/npm/cli/releases/tag/v8.0.0

(cherry picked from commit 34f486e)
  • Loading branch information
clydin committed Oct 19, 2021
1 parent 6173609 commit e011260
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/packages.ts
Expand Up @@ -86,7 +86,7 @@ function loadPackageJson(p: string) {
case 'engines':
pkg['engines'] = {
'node': '^12.14.1 || >=14.0.0',
'npm': '^6.11.0 || ^7.5.6',
'npm': '^6.11.0 || ^7.5.6 || >=8.0.0',
'yarn': '>= 1.13.0',
};
break;
Expand Down

0 comments on commit e011260

Please sign in to comment.