解决方法
需要配置路径为taobao的免费 registry,如下:
-
npm config set registry https://registry.npm.taobao.org
-
-- 配置后可通过下面方式来验证是否成功
-
npm config get registry或npm info express
其他命令:
卸载cnpm依赖:
npm uninstall -g cnpm --registry=https://registry.npm.taobao.org
卸指定下载地址安装:npm install
-g yarn --registry=https://registry.npm.taobao.org
