淘宝镜像:
npm install -g cnpm --registry=https://registry.npm.taobao.org
然后就可以使用cnpm代替npm
设置默认:
npm install -g cnpm --registry=https://registry.npm.taobao.org npm config set registry https://registry.npm.taobao.org
同步模块
直接通过 sync
命令马上同步一个模块, 只有 cnpm
命令行才有此功能:
cnpm sync connect
原文:https://www.cnblogs.com/EnderH/p/11157981.html