Skip to content

Commit 33097e7

Browse files
committed
feat(generators): add fall back for old app-scripts
1 parent 8d4975c commit 33097e7

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

packages/cli-plugin-ionic-angular/src/utils/generate.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ export async function prompt(context: AppScriptsType.BuildContext) {
2626
export async function getModules(context: AppScriptsType.BuildContext, kind: string) {
2727
switch (kind) {
2828
case 'component':
29-
return context.componentsNgModulePath;
29+
return context.componentsNgModulePath || context.appNgModulePath;
3030
case 'pipe':
31-
return context.pipesNgModulePath;
31+
return context.pipesNgModulePath || context.appNgModulePath;
3232
case 'directive':
33-
return context.directivesNgModulePath;
33+
return context.directivesNgModulePath || context.appNgModulePath;
3434
}
3535
}
3636

0 commit comments

Comments
 (0)