0
点赞
收藏
分享

微信扫一扫

Windows安装PM2 注意事项与错误查改

知年_7740 2024-11-06 阅读 10

npm设置镜像源

1、查看当前的npm镜像设置:

npm config list

2、清空缓存:

npm cache clean --force

3、设置镜像源

npm config set registry https://registry.npmmirror.com

// 常用的镜像源地址
# 淘宝镜像源
https://registry.npmmirror.com

# 腾讯云镜像源
http://mirrors.cloud.tencent.com/npm/

# 华为云镜像源
https://mirrors.huaweicloud.com/repository/npm/

# 官方默认全局镜像
https://registry.npmjs.org

4、查看当前使用的镜像地址

npm config get registry
举报

相关推荐

0 条评论