npm使用淘宝镜像源

npm使用淘宝镜像源

单次使用

npm install koa --registry=https://registry.npm.taobao.org

永久使用

配置淘宝镜像源

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

查看配置是否成功

npm config get registry

使用

npm install koa

cnpm

安装cnpm

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

检查安装是否成功

cnpm -v

使用

cnpm install koa
posted @ 2021-03-14 14:43  tanyiqu  阅读(19335)  评论(0编辑  收藏  举报