Skip to content

Commit

Permalink
feat(generators): refactor generators
Browse files Browse the repository at this point in the history
* feat(generators): update templates

* feat(generators): add pipeName to templates
  • Loading branch information
mhartington authored Jul 25, 2017
1 parent add0c4e commit 400aa54
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -148,4 +148,4 @@
"pre-push#master": [
"test"
]
}
}
3 changes: 0 additions & 3 deletions scripts/templates/page/module.ts.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,5 @@ import { $CLASSNAME } from './$FILENAME';
imports: [
IonicPageModule.forChild($CLASSNAME),
],
exports: [
$CLASSNAME
]
})
export class $CLASSNAMEModule {}
4 changes: 2 additions & 2 deletions scripts/templates/page/ts.tmpl
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Component } from '@angular/core';
import { NavController, NavParams } from 'ionic-angular';
$IMPORTSTATEMENT

/**
* Generated class for the $CLASSNAME page.
*
* See http://ionicframework.com/docs/components/#navigation for more info
* on Ionic pages and navigation.
*/

$IONICPAGE
@Component({
selector: 'page-$FILENAME',
templateUrl: '$FILENAME.html',
Expand Down
2 changes: 1 addition & 1 deletion scripts/templates/pipe/ts.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { Pipe, PipeTransform } from '@angular/core';
* Angular Pipes.
*/
@Pipe({
name: '$FILENAME',
name: '$PIPENAME',
})
export class $CLASSNAME implements PipeTransform {
/**
Expand Down
3 changes: 2 additions & 1 deletion scripts/templates/tabs/ts.tmpl
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { Component } from '@angular/core';
import { NavController } from 'ionic-angular';
$TABS_IMPORTSTATEMENT

/**
* Generated class for the $CLASSNAME tabs.
*
* See https://angular.io/docs/ts/latest/guide/dependency-injection.html for
* more info on providers and Angular DI.
*/
$IONICPAGE
@Component({
selector: 'page-$FILENAME',
templateUrl: '$FILENAME.html'
Expand Down

0 comments on commit 400aa54

Please sign in to comment.