npm审核修复--force

时间:2020-03-19 09:12:14

标签: npm dependencies npm-install

我想摆脱我的漏洞并使用

npm audit fix --force

但是我在几行之后取消了它,因为它说:“我希望你知道自己在做什么”

现在,如果我尝试

npm install

我明白了

$ npm install
npm WARN @angular-devkit/build-angular@0.900.7 requires a peer of typescript@>=3.6 < 3.8 but none is installed. You must install peer dependencies yourself.
npm WARN @ngtools/webpack@9.0.7 requires a peer of typescript@>=3.6 < 3.8 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/compiler-cli@9.0.7 requires a peer of typescript@>=3.6 <3.8 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/platform-browser-dynamic@8.1.3 requires a peer of @angular/compiler@8.1.3 but none is installed. You must install peer dependencies yourself.
npm WARN @ngtools/webpack@9.0.7 requires a peer of typescript@>=3.6 < 3.8 but none is installed. You must install peer dependencies yourself.
npm WARN ts-jest@24.0.2 requires a peer of jest@>=24 <25 but none is installed. You must install peer dependencies yourself.

audited 1219421 packages in 12.454s

39 packages are looking for funding
  run `npm fund` for details

found 23 vulnerabilities (21 low, 2 moderate)
  run `npm audit fix` to fix them, or `npm audit` for details

如果我安装@ angular / compiler @ 8.1.3,我需要@ angular / compiler @ 9.0.7,反之亦然

1 个答案:

答案 0 :(得分:-1)

我遇到了同样的问题,通过运行“ ng update”命令解决了该问题,该命令将为您提供需要更新的软件包以及用于更新它的命令。希望这对您有所帮助。