修改镜像源加速npm


1.查看当前使用的镜像源

npm config get registry

2.修改镜像源

临时修改

npm install 软件名 --registry https://registry.npm.taobao.org/

全局修改

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

3.使用第三方软件修改切换镜像源 nrm

安装nrm

npm install -g nrm

查看当前所有可用镜像源

nrm ls

使用淘宝镜像源

nrm use taobao

测试访问速度

nrm test taobao

from: https://learnku.com/articles/15975/npm-accelerate-and-modify-mirror-source-in-china


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM