IONIC 2模板

Geo*_*ang 30 ionic2

有谁知道我在哪里可以找到所有可用的Ionic 2启动模板?目前我知道ionic提供教程(似乎是v1中sidemenu的替代品),tabs,默认为空白.

我可以使用任何自定义模板ionic start [xx] tempName吗?

更新:目前(2017年2月27日),离子团队又添加了教程模板,他们还添加了一个名为super的新模板(包括登录,注册).

Guu*_*uus 55

ionic start --list
Run Code Online (Sandbox Code Playgroud)

得到:

blank ................ A blank starter project for Ionic
complex-list ......... A complex list starter template
maps ................. An Ionic starter project using Google Maps and a side menu
salesforce ........... A starter project for Ionic and Salesforce
sidemenu ............. A starting project for Ionic using a side menu with navigation in the content area
tabs ................. A starting project for Ionic using a simple tabbed interface
Run Code Online (Sandbox Code Playgroud)

更新:目前Ionic 3.7.0提供更多模板:

ubuntu@x.x.x.x:~/prj$ ionic start --list
tabs ............... ionic-angular A starting project with a simple tabbed interface
blank .............. ionic-angular A blank starter project
sidemenu ........... ionic-angular A starting project with a side menu with navigation in the content area
super .............. ionic-angular A starting project complete with pre-built pages, providers and best practices for Ionic development.
conference ......... ionic-angular A project that demonstrates a realworld application
tutorial ........... ionic-angular A tutorial based project that goes along with the Ionic documentation
aws ................ ionic-angular AWS Mobile Hub Starter
tabs ............... ionic1 A starting project for Ionic using a simple tabbed interface
blank .............. ionic1 A blank starter project for Ionic
sidemenu ........... ionic1 A starting project for Ionic using a side menu with navigation in the content area
maps ............... ionic1 An Ionic starter project using Google Maps and a side menu
Run Code Online (Sandbox Code Playgroud)

离子4模板

ionic start --list  

name     | project type  | description
--------------------------------------------------------------------------------------------------------------------------------
blank    | angular       | A blank starter project
sidemenu | angular       | A starting project with a side menu with navigation in the content area
tabs     | angular       | A starting project with a simple tabbed interface
tabs     | ionic-angular | A starting project with a simple tabbed interface
blank    | ionic-angular | A blank starter project
sidemenu | ionic-angular | A starting project with a side menu with navigation in the content area
super    | ionic-angular | A starting project complete with pre-built pages, providers and best practices for Ionic development.
tutorial | ionic-angular | A tutorial based project that goes along with the Ionic documentation
aws      | ionic-angular | AWS Mobile Hub Starter
tabs     | ionic1        | A starting project for Ionic using a simple tabbed interface
blank    | ionic1        | A blank starter project for Ionic
sidemenu | ionic1        | A starting project for Ionic using a side menu with navigation in the content area
maps     | ionic1        | An Ionic starter project using Google Maps and a side menu
Run Code Online (Sandbox Code Playgroud)

  • 这比链接到某些筛选列表要好得多. (2认同)
  • 不能在一段时间之后编辑评论......很奇怪......无论如何 - 他们列出的模板还没有准备好......让我们感到困惑并浪费时间的方式.是的,我们知道这是一个测试版,但即使是alpha软件也不会列出不可用的东西......"不幸的是,复杂的列表启动器还没有完成.还在进行中!"请查看https://github.com/driftyco /离子/问题/ 3939 (2认同)
  • 是啊,你说得对.我刚试过`complex-list`和`2.0.0-beta.32`现在它甚至崩溃了`错误启动错误:没有名为"complex-list"的启动器模板`他们应该把它留下来或添加注释`尚不可用. (2认同)

小智 20

我也在寻找.你提到的那些,似乎就是这样.Sidemenu也存在离子2,但到目前为止我还没有成功.

我没有找到任何其他人.

这是所有现有模板的链接


LeR*_*Roy 15

!当前(很可能会更改)您可以执行以下操作:--ts如果您需要打字稿,则可选.

ionic start tempName blank --v2 --ts

ionic start tempName tabs --v2 --ts

ionic start tempName base --v2 --ts

ionic start tempName sidemenu --v2 --ts
Run Code Online (Sandbox Code Playgroud)

更新.你不需要再指定--ts了.现在是默认的

ionic start tempName blank --v2
Run Code Online (Sandbox Code Playgroud)

更新我找到了完整列表,请注意有些尚未更新

1.具有Ionic Deploy功能的入门级应用程序,可在应用商店中实现应用的实时更新.

ionic start myApp deploy
Run Code Online (Sandbox Code Playgroud)

2,Ionic Framework的入门模板.您的基本电池包括Ionic入门应用程序,以及分析.

ionic start myApp analytics
Run Code Online (Sandbox Code Playgroud)

3.用于在Salesforce平台之上构建Ionic应用程序的入门包,该平台是作为Ionic和Salesforce之间的合作伙伴关系创建的.

 ionic start myApp salesforce
Run Code Online (Sandbox Code Playgroud)

4,使用谷歌地图和侧面菜单的离子启动项目

ionic start myApp maps 
Run Code Online (Sandbox Code Playgroud)

5.使用带有导航的侧面菜单的Ionic的起始项目

ionic start myApp sidemenu
Run Code Online (Sandbox Code Playgroud)

6,Ionic的空白启动项目

ionic start myApp blank --v2
Run Code Online (Sandbox Code Playgroud)

7.使用 Ionic,Three.js和WebGL构建Google Cardboard应用程序,作为Angular Cardboard Hackathon的一部分.

ionic start myApp cardboard
Run Code Online (Sandbox Code Playgroud)

8,使用简单的标签界面启动Ionic的项目

ionic start myTabs tabs --v2
Run Code Online (Sandbox Code Playgroud)

9.本教程与Ionic v2文档中的示例一起提供

ionic start myTutorial tutorial --v2
Run Code Online (Sandbox Code Playgroud)

10,含有ionic.io服务的离子启动项目.

ionic start myApp io
Run Code Online (Sandbox Code Playgroud)


S.Y*_*dav 12

对于离子2,这是了解模板的唯一命令 -

ionic start --list
Run Code Online (Sandbox Code Playgroud)

查看我当地的系统设置 -


D:\appsDir>ionic info

Your system information:

 ordova CLI: 6.4.0
Ionic CLI Version: 2.1.13
Ionic App Lib Version: 2.1.7
ios-deploy version: Not installe
ios-sim version: Not installed
OS: Windows 8
Node Version: v7.2.0
Xcode version: Not installed
Run Code Online (Sandbox Code Playgroud)

这将产生以下输出 -

D:\AppsDir>ionic start --list

Downloading Starter Templates - http://code.ionicframework.com/content/starter-t
emplates.json
Ionic Starter templates


blank ................ A blank starter project for Ionic
complex-list ......... A complex list starter template
maps ................. An Ionic starter project using Google Maps and a side men
u
salesforce ........... A starter project for Ionic and Salesforce
sidemenu ............. A starting project for Ionic using a side menu with navig
ation in the content area
tabs ................. A starting project for Ionic using a simple tabbed interface  
Run Code Online (Sandbox Code Playgroud)

除此之外,我们还有一些模板 -

$ ionic start appName tutorial --v2
Run Code Online (Sandbox Code Playgroud)

注意: - 不要将$用于Windows操作系统.

希望它能帮到你......


Geo*_*ang 5

您可以使用CLI命令:ionic模板或ionic start -l来查看开发计算机上“已安装”的所有可用模板。

  • “离子模板”似乎不是有效的命令。“ ionic start -l”会列出模板。 (2认同)

Naz*_*lam 5

您可以使用以下cli命令使用侧面菜单模板创建ionic 2项目:

ionic start your_project_name  --v2 sidemenu
Run Code Online (Sandbox Code Playgroud)