问题描述:
项目安装npm包出现core-js没有安装上> core-js-pure@3.11.0 postinstall E:\EnjoyGOV\node_modules\core-js-pure
> node -e "try{require('./postinstall')}catch(e){}"
Thank you for using core-js ( https://github.com/zloirock/core-js ) for polyfilling JavaScript standard library!
The project needs your help! Please consider supporting of core-js on Open Collective or Patreon:
> https://opencollective.com/core-js
> https://www.patreon.com/zloirock
Also, the author of core-js ( https://github.com/zloirock ) is looking for a good job -)
> core-js@3.11.0 postinstall E:\EnjoyGOV\node_modules\jspdf\node_modules\core-js
> node -e "try{require('./postinstall')}catch(e){}"
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
added 877 packages from 626 contributors and audited 950 packages in 53.95s
2 packages are looking for funding
run `npm fund` for details
found 150 vulnerabilities (12 low, 42 moderate, 75 high, 21 critical)
run `npm audit fix` to fix them, or `npm audit` for details
因为 npm 安装模块的时候 unsafe-perm 配置出错,要添加以下配置
npm config set unsafe-perm true
然后重新删除包再cnpm i或者yarn
本文指导如何在项目中安装core-js遇到的问题,涉及npm配置、postinstall警告及处理方式,包括设置`unsafe-perm`并重新安装包的步骤,以及解决fsevents optional dependency的警告。

1639

被折叠的 条评论
为什么被折叠?



