首页 > 其他 > 详细

npm 淘宝镜像与官方源 切换

时间:2020-04-10 15:54:47      阅读:55      评论:0      收藏:0      [点我收藏+]

1.临时使用

npm --registry https://registry.npm.taobao.org install 包名

 

2.永久设置为淘宝镜像

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

 

3.换回国外官方源

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

 

4.查看使用的源地址

npm config get registry

 

5.使用淘宝的cnpm

npm install -g cnpm --registry=https://registry.npm.taobao.org

 

npm 淘宝镜像与官方源 切换

原文:https://www.cnblogs.com/tian1206/p/12673161.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!