ServiceWorker.scriptURL

Returns the ServiceWorker serialized script URL defined as part of ServiceWorkerRegistration. Must be on the same origin as the document that registers the ServiceWorker.

Syntax

someURL = ServiceWorker.scriptURL

Value

A USVString (see the WebIDL definition of USVString.)

Examples

TBD

Specifications

Specification Status Comment
Service Workers
The definition of 'scriptURL' in that specification.
Working Draft Initial definition

Browser compatibility

BCD tables only load in the browser