Skip to content

Commit

Permalink
refactor(core): flatten and resolve ng-module bootstrap info in local…
Browse files Browse the repository at this point in the history
… compilation mode

TODO
  • Loading branch information
pmvald committed Sep 5, 2023
1 parent 062241f commit eb8af8e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
7 changes: 7 additions & 0 deletions packages/core/src/render3/interfaces/definition.ts
Original file line number Diff line number Diff line change
Expand Up @@ -550,4 +550,11 @@ export interface NgModuleScopeInfoFromDecorator {
* module.
*/
exports?: FullAotScopeInfoFromDecorator|NgModule['exports'];

/**
* The set of components that are bootstrapped when this module is bootstrapped. This field is
* only available in local compilation mode. In full compilation mode bootstrap info is passed
* directly to the module def runtime after statically analyzed and resolved.
*/
bootstrap?: NgModule['bootstrap'];
}
1 change: 1 addition & 0 deletions packages/core/src/render3/scope.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ export function ɵɵsetNgModuleScope(type: any, scope: NgModuleScopeInfoFromDeco
ngModuleDef.declarations = convertToTypeArray(scope.declarations || EMPTY_ARRAY);
ngModuleDef.imports = convertToTypeArray(scope.imports || EMPTY_ARRAY);
ngModuleDef.exports = convertToTypeArray(scope.exports || EMPTY_ARRAY);
ngModuleDef.bootstrap = convertToTypeArray(scope.bootstrap || EMPTY_ARRAY);

depsTracker.registerNgModule(type, scope);
});
Expand Down

0 comments on commit eb8af8e

Please sign in to comment.