MCPcopy Index your code
hub / github.com/angular/angular / provideAppInitializer

Function provideAppInitializer

packages/core/src/application/application_init.ts:192–202  ·  view source on GitHub ↗
(
  initializerFn: () => Observable<unknown> | Promise<unknown> | void,
)

Source from the content-addressed store, hash-verified

190 * @publicApi
191 */
192export function provideAppInitializer(
193 initializerFn: () => Observable<unknown> | Promise<unknown> | void,
194): EnvironmentProviders {
195 return makeEnvironmentProviders([
196 {
197 provide: APP_INITIALIZER,
198 multi: true,
199 useValue: initializerFn,
200 },
201 ]);
202}
203
204/**
205 * A class that reflects the state of running {@link APP_INITIALIZER} functions.

Callers 9

provideServiceWorkerFunction · 0.90
TestClass · 0.90
app.config.tsFile · 0.90
provideSettingsFunction · 0.90
app.config.tsFile · 0.90

Calls 1

makeEnvironmentProvidersFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…