ionic@2.0 beta版本安装指南

由于访问npm官方源下载ionic速度缓慢,淘宝提供了npm源,方便国内人士访问。

1.通过config命令

npm config set registry https://registry.npm.taobao.org 
npm info ionic (如果上面配置正确这个命令会有字符串response)

2.命令行指定

npm --registry https://registry.npm.taobao.org info ionic 

3.编辑 ~/.npmrc 加入下面内容

registry = https://registry.npm.taobao.org

搜索镜像: https://npm.taobao.org

建立或使用镜像,参考: https://github.com/cnpm/cnpmjs.org

修改好源之后,可以看看ionic的版本信息

npm info ionic

找到相应的版本然后安装

sudo npm install -g ionic@版本号

安装完成之后,即可使用ionic创建应用啦。
原文地址:https://www.cnblogs.com/jone-chen/p/5688497.html