WorkerLocation.origin
The origin property of a WorkerLocation object returns the worker's origin.
Syntax
string = object.origin;
Examples
// On this page, returns the origin
var result = self.location.origin; // Returns:'https://developer.mozilla.org:443'
Specifications
| Specification |
|---|
| HTML Standard # dom-workerlocation-origin |
Browser compatibility
BCD tables only load in the browser
See also
- The
WorkerLocationinterface it belongs to.