mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-20 04:14:21 +08:00
fix(generators): replace tabs code lost by atom crashing
This commit is contained in:
@ -1,5 +1,5 @@
|
||||
<ion-tabs>
|
||||
<% _.forEach(tabs, function(tab, i) { %>
|
||||
<ion-tab [root]="tab<%= ++i %>Root" tab-title="<%= tab.name %>" tab-icon="star"></ion-tab>
|
||||
<ion-tab [root]="tab<%= ++i %>Root" tabTitle="<%= tab.name %>" tabIcon="star"></ion-tab>
|
||||
<% }); %>
|
||||
</ion-tabs>
|
||||
|
@ -1,3 +1,14 @@
|
||||
import {NavController, Page} from 'ionic/ionic';
|
||||
<% _.forEach(tabs, function(tab) { %>import {<%= tab.jsClassName %>} from '../<%= tab.fileName %>/<%= tab.fileName %>';
|
||||
<% }); %>
|
||||
|
||||
|
||||
@Page({
|
||||
templateUrl: 'build/<%= directory %>/<%= fileName %>/<%= fileName %>.html'
|
||||
})
|
||||
export class <%= jsClassName %> {
|
||||
constructor(nav: NavController) {
|
||||
// set the root pages for each tab
|
||||
<% _.forEach(tabs, function(tab, i) { %>this.tab<%= ++i %>Root = <%= tab.jsClassName %>;
|
||||
<% }); %>
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user