refactor(core): introduce APP_BOOTSTRAP_LISTENER
multi provider
Using the `registerBootstrapListener` easily lead to race condition and needed dependencies on `ApplicationRef`. BREAKING CHANGE: - `ApplicationRef.registerBootstrapListener` is deprecated. Provide a multi provider for the new token `APP_BOOTSTRAP_LISTENER` instead.
This commit is contained in:
@ -53,6 +53,13 @@ export const PLATFORM_INITIALIZER: any = new OpaqueToken('Platform Initializer')
|
||||
*/
|
||||
export const APP_INITIALIZER: any = new OpaqueToken('Application Initializer');
|
||||
|
||||
/**
|
||||
* All callbacks provided via this token will be called when a component has been bootstrapped.
|
||||
*
|
||||
* @experimental
|
||||
*/
|
||||
export const APP_BOOTSTRAP_LISTENER = new OpaqueToken('appBootstrapListener');
|
||||
|
||||
/**
|
||||
* A token which indicates the root directory of the application
|
||||
* @experimental
|
||||
|
Reference in New Issue
Block a user