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

Function provideServiceWorker

packages/service-worker/src/provider.ts:240–255  ·  view source on GitHub ↗
(
  script: string,
  options: SwRegistrationOptions = {},
)

Source from the content-addressed store, hash-verified

238 *
239 */
240export function provideServiceWorker(
241 script: string,
242 options: SwRegistrationOptions = {},
243): EnvironmentProviders {
244 return makeEnvironmentProviders([
245 SwPush,
246 SwUpdate,
247 {provide: SCRIPT, useValue: script},
248 {provide: SwRegistrationOptions, useValue: options},
249 {
250 provide: NgswCommChannel,
251 useFactory: ngswCommChannelFactory,
252 },
253 provideAppInitializer(ngswAppInitializer),
254 ]);
255}

Callers 3

configTestBedFunction · 0.90
registerMethod · 0.90

Calls 2

makeEnvironmentProvidersFunction · 0.90
provideAppInitializerFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…