refactor(core): rename precompile
into entryComponents
.
Part of #10043 BREAKING CHANGE: - `@Component.precompile` was renamed to `@Component.entryComponents` (old property still works but is deprecated) - `ANALYZE_FOR_PRECOMPILE` was renamed to `ANALYZE_FOR_ENTRY_COMPONENTS` (no deprecations)
This commit is contained in:
@ -65,7 +65,7 @@ export class Compiler {
|
||||
`Runtime compiler is not loaded. Tried to compile ${stringify(component)}`);
|
||||
}
|
||||
/**
|
||||
* Compiles the given NgModule. All templates of the components listed in `precompile`
|
||||
* Compiles the given NgModule. All templates of the components listed in `entryComponents`
|
||||
* have to be either inline or compiled before via `compileComponentAsync` /
|
||||
* `compileModuleAsync`. Otherwise throws a {@link ComponentStillLoadingError}.
|
||||
*/
|
||||
|
@ -14,13 +14,13 @@ import {ComponentFactory} from './component_factory';
|
||||
* can later be used to create and render a Component instance.
|
||||
*
|
||||
* @deprecated Use {@link ComponentFactoryResolver} together with {@link
|
||||
* NgModule}.precompile}/{@link Component}.precompile or
|
||||
* {@link ANALYZE_FOR_PRECOMPILE} provider for dynamic component creation.
|
||||
* NgModule}.entryComponents}/{@link Component}.entryComponents or
|
||||
* {@link ANALYZE_FOR_ENTRY_COMPONENTS} provider for dynamic component creation.
|
||||
* Use {@link NgModuleFactoryLoader} for lazy loading.
|
||||
*/
|
||||
export abstract class ComponentResolver {
|
||||
static DynamicCompilationDeprecationMsg =
|
||||
'ComponentResolver is deprecated for dynamic compilation. Use ComponentFactoryResolver together with @NgModule/@Component.precompile or ANALYZE_FOR_PRECOMPILE provider instead. For runtime compile only, you can also use Compiler.compileComponentSync/Async.';
|
||||
'ComponentResolver is deprecated for dynamic compilation. Use ComponentFactoryResolver together with @NgModule/@Component.entryComponents or ANALYZE_FOR_ENTRY_COMPONENTS provider instead. For runtime compile only, you can also use Compiler.compileComponentSync/Async.';
|
||||
static LazyLoadingDeprecationMsg =
|
||||
'ComponentResolver is deprecated for lazy loading. Use NgModuleFactoryLoader instead.';
|
||||
|
||||
|
@ -29,7 +29,7 @@ export abstract class NgModuleRef<T> {
|
||||
|
||||
/**
|
||||
* The ComponentFactoryResolver to get hold of the ComponentFactories
|
||||
* delcared in the `precompile` property of the module.
|
||||
* delcared in the `entryComponents` property of the module.
|
||||
*/
|
||||
get componentFactoryResolver(): ComponentFactoryResolver { return unimplemented(); }
|
||||
|
||||
|
Reference in New Issue
Block a user