Skip to content

Commit 06d332b

Browse files
committed
feat(@angular/cli): generate --helpJson will remove collection name
For the default collection.
1 parent 3b5dbad commit 06d332b

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

packages/angular/cli/commands/generate-impl.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,11 @@ export class GenerateCommand extends SchematicCommand<GenerateCommandSchema> {
3737
);
3838
}
3939

40-
this.description.suboptions[`${collectionName}:${name}`] = options;
40+
if (this.getDefaultSchematicCollection() == collectionName) {
41+
this.description.suboptions[name] = options;
42+
} else {
43+
this.description.suboptions[`${collectionName}:${name}`] = options;
44+
}
4145
}
4246

4347
this.description.options.forEach(option => {

0 commit comments

Comments
 (0)