我正在重新安装我的 MacBook。我在安装 (npm install -g @angular/cli) angular 时收到以下消息。知道为什么吗?我怀疑 nom 版本,但我与 node 一起出现……
Developments npm install -g @angular/cli
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@angular/cli@11.1.4',
npm WARN EBADENGINE required: { node: '>= 10.13.0', npm: '^6.11.0', yarn: '>= 1.13.0' },
npm WARN EBADENGINE current: { node: 'v15.8.0', npm: '7.5.2' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@angular-devkit/architect@0.1101.4',
npm WARN EBADENGINE required: { node: '>= 10.13.0', npm: '^6.11.0', yarn: '>= 1.13.0' },
npm WARN EBADENGINE current: { node: 'v15.8.0', npm: '7.5.2' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@angular-devkit/core@11.1.4',
npm WARN EBADENGINE required: { node: '>= 10.13.0', npm: '^6.11.0', yarn: '>= 1.13.0' },
npm WARN EBADENGINE current: { node: 'v15.8.0', npm: '7.5.2' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@angular-devkit/schematics@11.1.4',
npm WARN EBADENGINE required: { node: '>= 10.13.0', npm: '^6.11.0', yarn: '>= 1.13.0' },
npm WARN EBADENGINE current: { node: 'v15.8.0', npm: '7.5.2' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@schematics/angular@11.1.4',
npm WARN EBADENGINE required: { node: '>= 10.13.0', npm: '^6.11.0', yarn: '>= 1.13.0' },
npm WARN EBADENGINE current: { node: 'v15.8.0', npm: '7.5.2' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@schematics/update@0.1101.4',
npm WARN EBADENGINE required: { node: '>= 10.13.0', npm: '^6.11.0', yarn: '>= 1.13.0' },
npm WARN EBADENGINE current: { node: 'v15.8.0', npm: '7.5.2' }
npm WARN EBADENGINE }
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
added 241 packages, and audited 242 packages in 12s
20 packages are looking for funding
run `npm fund` for details
found 0 vulnerabilities
原文由 Jean-Philippe M 发布,翻译遵循 CC BY-SA 4.0 许可协议
更新 - 2021 年 2 月 25 日
npm
7.5.6
or greater now works withangular-cli
versions9.1.15
,10.2.3
,11.2.2
,12.0.0-next.2
根据 Angular 团队的 _评论_,或更高 版本(在每个主要版本中)原始信息 - 2021 年 2 月 7 日
在编写 npm 7 时,
angular-cli
根据 此 GitHub 问题 不完全支持我在 Windows 上也收到相同的警告
current: { node: 'v15.4.0', npm: '7.5.2' }
当我使用 npm 7 运行
ng new
时,Angular CLI 会返回警告并提供解决方法npm 7 于 2021 年 2 月 2 日正式发布
这是一个持续存在的问题,npm 团队最近 添加了一条评论,以回应 Angular 团队对上述 GitHub 问题的回应。