Skip to content

Commit 2d8eec2

Browse files
committed
feat(@angular/cli): support additional application lazy modules
1 parent 4b507fd commit 2d8eec2

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

packages/@angular/cli/lib/config/schema.json

+8
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,14 @@
263263
"description": "Name and corresponding file for environment config.",
264264
"type": "object",
265265
"additionalProperties": true
266+
},
267+
"lazyModules": {
268+
"description": "List of additional NgModules that will be lazy loaded. (lazy router modules with be discovered automatically)",
269+
"type": "array",
270+
"items": {
271+
"type": "object",
272+
"additionalProperties": { "type": "string" }
273+
}
266274
}
267275
},
268276
"additionalProperties": false

packages/@angular/cli/models/webpack-configs/typescript.ts

+1
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ function _createAotPlugin(wco: WebpackConfigOptions, options: any, useMain = tru
9292
missingTranslation: buildOptions.missingTranslation,
9393
hostReplacementPaths,
9494
sourceMap: buildOptions.sourcemaps,
95+
additionalLazyModules: appConfig.lazyModules,
9596
}, options);
9697
return new AngularCompilerPlugin(pluginOptions);
9798
} else {

0 commit comments

Comments
 (0)