【问题标题】:How to create ionic 2 app如何创建 ionic 2 应用程序
【发布时间】:2017-07-25 08:49:59
【问题描述】:

我是 ionic2 新手,无法创建 ionic2 应用

如果我运行这个命令

它将创建 ionic3

$ npm install -g ionic cordova

如果我运行这个命令会出错

npm install -g ionic@2.3.0

错误

npm ERR! code ETARGET
npm ERR! notarget No matching version found for ionic@2.3.0
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\abc\AppData\Roaming\npm-cache\_logs\2017-07-25T08_11_14_543Z-debug.log

【问题讨论】:

  • 类似的问题TOPIC
  • 我应该运行什么命令来安装ionic2的所有依赖项

标签: ionic2


【解决方案1】:

ionic 2.2.3 不存在,释放ionic 2.2.0 后,ionic cli 版本移至3.0.0

npm install -g ionic@2.2.0 可以工作。

要创建 ionic 2 项目,您需要在项目中更改 ionic-angular 的版本,而不是在 ionic-cli 中。

Ionic framework (ionic-angular) 和 ionic-cli 都是不同的。

CHANGELOG v2.x.x.

CHANGELOG v3.x.x.

【讨论】:

  • 离子框架(ionic-angular)和ionic-cli有什么区别
  • 你能给我解释一下吗
  • 你可以google一下。我希望你能得到你的问题的答案。
  • 如何更改 ionic-angular 的版本
  • 在您的项目 package.json 中。但是为什么你想要那个,3更好。我希望你能得到这个问题的答案。
【解决方案2】:

请参考a link!了解 ionic 和 ionic-angular 之间的区别和 要创建 ionic2,请参考此a link

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2016-05-15
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-07-13
    • 2016-02-01
    • 2016-11-30
    • 1970-01-01
    相关资源
    最近更新 更多