配置 npm 国内镜像(重要!)
npm 默认从国外服务器下载包,在国内会很慢甚至超时。一条命令切换到淘宝镜像:
npm config set registry https://registry.npmmirror.com
验证:
npm config get registry
指定npm镜像
-
npm 官方原始镜像网址是:https://registry.npmjs.org/
淘宝 NPM 镜像:http://registry.npmmirror.com
阿里云 NPM 镜像:https://npm.aliyun.com
腾讯云 NPM 镜像:https://mirrors.cloud.tencent.com/npm/
华为云 NPM 镜像:https://mirrors.huaweicloud.com/repository/npm/
网易 NPM 镜像:https://mirrors.163.com/npm/
中国科学技术大学开源镜像站:http://mirrors.ustc.edu.cn/
清华大学开源镜像站:https://mirrors.tuna.tsinghua.edu.cn/
腾讯,华为,阿里的镜像站基本上比较全
活到老,学到老。

浙公网安备 33010602011771号