我正在尝试通过 npm 安装 react 但它给了我这个错误error An unexpected error occurred: "EPERM: operation not permitted, copyfile 'C:\\Users\\Bilal\\AppData\\Local\\Yarn\\Cache\\v6\\npm-request-2.88.2-d73c918731cb5a87da047e207234146f664d12b3-integrity\\node_modules\\request\\lib\\cookies.js' -> 'G:\\my-react\\node_modules\\request\\lib\\cookies.js'".我用了很多命令都没有用
4 回答
翻过高山走不出你
TA贡献1875条经验 获得超3个赞
我有同样的问题,我所做的是改用这个命令,这样它就不会从本地缓存复制文件
create-react-app your_app_name --use-npm --cache /tmp/empty-cache
MM们
TA贡献1886条经验 获得超2个赞
可能的解决方案:
1. Download latest recommended version of NodeJS
2. Uninstall current version from Control Panel
3. Go to C:\Users\{YourUsername}\AppData\Roaming folder and delete npm and npm-cache folders
4. Run installer of NodeJS
5. Update NPM to latest with npm i -g npm@latest command line
添加回答
举报
0/150
提交
取消
