npm
查看当前镜像源:
npm config get registry
# https://registry.npmjs.org/
修改当前镜像源:
npm config set registry https://registry.npmjs.org/
cnpm
安装 cnpm:
npm install cnpm -g
查看当前镜像源:
cnpm config get registry
# https://registry.npm.example.com
修改当前镜像源:
cnpm config set registry https://registry.npm.example.com