refactor(upgrade): re-export the new static upgrade APIs on new entry
Add upgrade-static.umd.js bundles This allows depending on it without getting a transitive dependency on compiler. BREAKING CHANGE: Four newly added APIs in 2.2.0-beta: downgradeComponent, downgradeInjectable, UpgradeComponent, and UpgradeModule are no longer exported by @angular/upgrade. Import these from @angular/upgrade/static instead.
This commit is contained in:
23
tools/public_api_guard/upgrade/index.d.ts
vendored
23
tools/public_api_guard/upgrade/index.d.ts
vendored
@ -1,9 +1,3 @@
|
||||
/** @experimental */
|
||||
export declare function downgradeComponent(info: ComponentInfo): angular.IInjectable;
|
||||
|
||||
/** @experimental */
|
||||
export declare function downgradeInjectable(token: any): (string | ((i: Injector) => any))[];
|
||||
|
||||
/** @stable */
|
||||
export declare class UpgradeAdapter {
|
||||
constructor(ng2AppModule: Type<any>, compilerOptions?: CompilerOptions);
|
||||
@ -25,20 +19,3 @@ export declare class UpgradeAdapterRef {
|
||||
dispose(): void;
|
||||
ready(fn: (upgradeAdapterRef?: UpgradeAdapterRef) => void): void;
|
||||
}
|
||||
|
||||
/** @experimental */
|
||||
export declare class UpgradeComponent implements OnInit, OnChanges, DoCheck {
|
||||
constructor(name: string, elementRef: ElementRef, injector: Injector);
|
||||
ngDoCheck(): void;
|
||||
ngOnChanges(changes: SimpleChanges): void;
|
||||
ngOnInit(): void;
|
||||
}
|
||||
|
||||
/** @experimental */
|
||||
export declare class UpgradeModule {
|
||||
$injector: angular.IInjectorService;
|
||||
injector: Injector;
|
||||
ngZone: NgZone;
|
||||
constructor(injector: Injector, ngZone: NgZone);
|
||||
bootstrap(element: Element, modules?: string[], config?: angular.IAngularBootstrapConfig): void;
|
||||
}
|
||||
|
22
tools/public_api_guard/upgrade/static.d.ts
vendored
Normal file
22
tools/public_api_guard/upgrade/static.d.ts
vendored
Normal file
@ -0,0 +1,22 @@
|
||||
/** @experimental */
|
||||
export declare function downgradeComponent(info: ComponentInfo): angular.IInjectable;
|
||||
|
||||
/** @experimental */
|
||||
export declare function downgradeInjectable(token: any): (string | ((i: Injector) => any))[];
|
||||
|
||||
/** @experimental */
|
||||
export declare class UpgradeComponent implements OnInit, OnChanges, DoCheck {
|
||||
constructor(name: string, elementRef: ElementRef, injector: Injector);
|
||||
ngDoCheck(): void;
|
||||
ngOnChanges(changes: SimpleChanges): void;
|
||||
ngOnInit(): void;
|
||||
}
|
||||
|
||||
/** @experimental */
|
||||
export declare class UpgradeModule {
|
||||
$injector: angular.IInjectorService;
|
||||
injector: Injector;
|
||||
ngZone: NgZone;
|
||||
constructor(injector: Injector, ngZone: NgZone);
|
||||
bootstrap(element: Element, modules?: string[], config?: angular.IAngularBootstrapConfig): void;
|
||||
}
|
Reference in New Issue
Block a user