Class: ServiceWorkerManager#

@jupyterlite/server.ServiceWorkerManager

Implements#

Constructors#

constructor#

new ServiceWorkerManager(options?)

Parameters#

Name

Type

options?

IOptions

Defined in#

packages/server/src/service-manager.ts:11

Properties#

_ready#

Private _ready: PromiseDelegate<void>

Defined in#

packages/server/src/service-manager.ts:117

_registration#

Private _registration: null | ServiceWorkerRegistration = null

Defined in#

packages/server/src/service-manager.ts:113

_registrationChanged#

Private _registrationChanged: Signal<ServiceWorkerManager, null | ServiceWorkerRegistration>

Defined in#

packages/server/src/service-manager.ts:114

Accessors#

enabled#

get enabled(): boolean

Whether the ServiceWorker is enabled or not.

Returns#

boolean

Implementation of#

IServiceWorkerManager.enabled

Defined in#

packages/server/src/service-manager.ts:33

ready#

get ready(): Promise<void>

Returns#

Promise<void>

Implementation of#

IServiceWorkerManager.ready

Defined in#

packages/server/src/service-manager.ts:37

registrationChanged#

get registrationChanged(): ISignal<IServiceWorkerManager, null | ServiceWorkerRegistration>

A signal emitted when the registration changes.

Returns#

ISignal<IServiceWorkerManager, null | ServiceWorkerRegistration>

Implementation of#

IServiceWorkerManager.registrationChanged

Defined in#

packages/server/src/service-manager.ts:23

Methods#

_pingServiceWorker#

Private _pingServiceWorker(): Promise<void>

Returns#

Promise<void>

Defined in#

packages/server/src/service-manager.ts:101

_setRegistration#

Private _setRegistration(registration): void

Parameters#

Name

Type

registration

null | ServiceWorkerRegistration

Returns#

void

Defined in#

packages/server/src/service-manager.ts:108

initialize#

Private initialize(workerUrl): Promise<void>

Parameters#

Name

Type

workerUrl

string

Returns#

Promise<void>

Defined in#

packages/server/src/service-manager.ts:61

unregisterOldServiceWorkers#

Private unregisterOldServiceWorkers(scriptURL): Promise<void>

Parameters#

Name

Type

scriptURL

string

Returns#

Promise<void>

Defined in#

packages/server/src/service-manager.ts:41