npm i
1、报错npm ERR! code EINTEGRITY
npm ERR! sha1-S/uhWonAaXIgtV94e7ywWkYdVII=sha512-+TkAPBQw4Cp2bQrSPtPNkhET7XcWYjjDt1UjWYQs+xbT41q5OAl1I3IZyhg0drjn1nlC1K0f8sLVB/nshUcF1Q== integrity checksum failed when using sha1: wanted sha1-S/uhWonAaXIgtV94e7ywWkYdVII=sha512-+TkAPBQw4Cp2bQrSPtPNkhET7XcWYjjDt1UjWYQs+xbT41q5OAl1I3IZyhg0drjn1nlC1K0f8sLVB/nshUcF1Q== but got sha1-S/uhWonAaXIgtV94e7ywWkYdVII=. (103754 bytes)
使用npm cache clean --force报错
npm cache clean --force
D:\work\zhyk\xboot-plus-front>npm cache clean --force
npm WARN using --force Recommended protections disabled.
然后降npm版本
npm install npm@6.14.10 -g
继续执行
npm cache clean --force
会提示npm WARN using --force I sure hope you know what you are doing.
然后执行
npm install
我用的windows 10专业版,
目前运行起来项目的版本是 node -v v16.17.0 和npm -v 6.14.10
可用命令行进行查看。记得哪个文件报错找哪个文件呀!
2、npm ERR! Cannot read properties of null (reading ‘package’)
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\zj100\AppData\Local\npm-cache_logs\2022-10-09T00_32_18_959Z-debug-0.log
解决办法: