-
-
Notifications
You must be signed in to change notification settings - Fork 78
Expand file tree
/
Copy pathgenerator.js
More file actions
23 lines (20 loc) · 918 Bytes
/
generator.js
File metadata and controls
23 lines (20 loc) · 918 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import BaseApplicationGenerator from 'generator-jhipster/generators/base-application';
export default class extends BaseApplicationGenerator {
constructor(args, opts, features) {
super(args, opts, { ...features, queueCommandTasks: true, sbsBlueprint: true });
}
async beforeQueue() {
await this.dependsOnJHipster('bootstrap-application');
}
get [BaseApplicationGenerator.COMPOSING]() {
return this.asComposingTaskGroup({
async composeTask() {
if (this.blueprintConfig.auditPage && ['angularX', 'angular'].includes(this.jhipsterConfigWithDefaults.clientFramework)) {
await this.composeWithJHipster('jhipster-entity-audit:angular-audit');
} else if (this.blueprintConfig.auditPage && ['vue'].includes(this.jhipsterConfigWithDefaults.clientFramework)) {
await this.composeWithJHipster('jhipster-entity-audit:vue-audit');
}
},
});
}
}