NPM安装依赖卡慢的解决方法

  1. 查看镜像使用状态
    1
    npm config get registry
    如果返回 https://registry.npmmirror.co 说明配置的是淘宝镜像。

  2. 设置淘宝镜像源
    1
    npm config set registry https://registry.npmmirror.com
    恢复官方镜像源
    1
    npm config set registry https://registry.npmjs.org