天天看点

npm install报错error 404 Not Found - GET https://registry.npm.taobao.org/@xt1.问题场景: 2.解决办法

1.问题场景:

vue cli3老项目重启,npm install安装报错。

错误信息:

4327 error code E404

4328 error 404 Not Found - GET https://registry.npm.taobao.org/@xtuc/long/-/long-4.2.1.tgz - [not_found] document not found

npm install报错error 404 Not Found - GET https://registry.npm.taobao.org/@xt1.问题场景: 2.解决办法

 2.解决办法

2.1先查看有没有设置代理

执行下面的命令

npm config get proxy
npm config get https-proxy
           

如果返回的不是null,则执行下面对命令清理;如果返回的是null,直接进入到第2步。

npm config set https-proxy null
npm config set proxy null
           

2.2重新设置

npm config set registry https://registry.npmjs.org/
           

到这里就完成了。执行npm install安装成功。

继续阅读