利用yrm快速切换npm和yarn镜像源

111 阅读1分钟

安装

npm install -g yrm

查看可切换镜像源列表

yrm ls

    npm -----  https://registry.npmjs.org/
    cnpm ----  http://r.cnpmjs.org/
    taobao --  https://registry.npm.taobao.org/
    nj ------  https://registry.nodejitsu.com/
    rednpm -- http://registry.mirror.cqupt.edu.cn
    skimdb -- https://skimdb.npmjs.com/registry
    yarn ----  https://registry.yarnpkg.com

使用指定镜像源

yrm use taobao

测试访问速度

yrm test taobao