Skip to content

Commit

Permalink
Merge branch 'master' into remove_travis_custom_launcher
Browse files Browse the repository at this point in the history
  • Loading branch information
andyskw authored Aug 24, 2016
2 parents 4df3a66 + f9df8bb commit e25cbf6
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions addon/ng2/blueprints/directive/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,24 @@ module.exports = {
description: '',

availableOptions: [
{ name: 'flat', type: Boolean, default: true }
{ name: 'flat', type: Boolean, default: true },
{ name: 'prefix', type: Boolean, default: true }
],

normalizeEntityName: function (entityName) {
var parsedPath = dynamicPathParser(this.project, entityName);

this.dynamicPath = parsedPath;
this.rawEntityName = parsedPath.name;

var defaultPrefix = '';
if (this.project.ngConfig &&
this.project.ngConfig.apps[0] &&
this.project.ngConfig.apps[0].prefix) {
defaultPrefix = this.project.ngConfig.apps[0].prefix;
}
var prefix = this.options.prefix ? defaultPrefix : '';

this.rawEntityName = prefix + parsedPath.name;
return parsedPath.name;
},

Expand Down

0 comments on commit e25cbf6

Please sign in to comment.