File tree Expand file tree Collapse file tree 3 files changed +48
-0
lines changed
Expand file tree Collapse file tree 3 files changed +48
-0
lines changed Original file line number Diff line number Diff line change 1+ export enum < %= classifiedModuleName % > {
2+
3+ }
Original file line number Diff line number Diff line change 1+ const stringUtils = require ( 'ember-cli-string-utils' ) ;
2+ var dynamicPathParser = require ( '../../utilities/dynamic-path-parser' ) ;
3+ var addBarrelRegistration = require ( '../../utilities/barrel-management' ) ;
4+
5+ module . exports = {
6+ description : '' ,
7+
8+ normalizeEntityName : function ( entityName ) {
9+ var parsedPath = dynamicPathParser ( this . project , entityName ) ;
10+
11+ this . dynamicPath = parsedPath ;
12+ return parsedPath . name ;
13+ } ,
14+
15+ locals : function ( options ) {
16+ this . fileName = stringUtils . dasherize ( options . entity . name ) ;
17+
18+ return {
19+ dynamicPath : this . dynamicPath . dir ,
20+ flat : options . flat ,
21+ fileName : this . fileName
22+ } ;
23+ } ,
24+
25+ fileMapTokens : function ( ) {
26+ // Return custom template variables here.
27+ return {
28+ __path__ : ( ) => {
29+ this . generatePath = this . dynamicPath . dir ;
30+ return this . generatePath ;
31+ } ,
32+ __name__ : ( ) => {
33+ return this . fileName ;
34+ }
35+ } ;
36+ } ,
37+
38+ afterInstall : function ( ) {
39+ return addBarrelRegistration (
40+ this ,
41+ this . generatePath ,
42+ this . fileName ) ;
43+ }
44+ } ;
Original file line number Diff line number Diff line change @@ -52,6 +52,7 @@ const aliasMap = {
5252 'cl' : 'class' ,
5353 'c' : 'component' ,
5454 'd' : 'directive' ,
55+ 'e' : 'enum' ,
5556 'p' : 'pipe' ,
5657 'r' : 'route' ,
5758 's' : 'service'
You can’t perform that action at this time.
0 commit comments