npm cnpm 切换
方法一: 安装cnpm
1.安装淘宝cnpm
npm install -g cnpm --registry=https://registry.npm.taobao.org
2.直接cnpm使用
cnpm install
方法二: 切换npm镜像地址
1.切换到淘宝cnpm
npm config set registry https://registry.npm.taobao.org
2.检查
npm config get registry
3.还原npm
npm config set registry https://registry.npmjs.org