Contact emails
mk...@chromium.orgSpec
https://html.spec.whatwg.org/multipage/webappapis.html#dom-origin
Summary
`self.origin` returns the Unicode serialization of the origin of the settings object of the global represented by `self` (a Window or WorkerGlobalScope). This gives scripts a consistent way of getting their origin in both situations. Note that unlike `location.origin` this represents the actual origin of the global, not the origin of the URL it's loaded from. The difference can be substantial in the case of sandboxing, for example.Motivation
We don't currently expose origin information inside workers; we should. This is a bit duplicative with `document.origin` in the `Window` case, but provides a stable accessor for all contexts going forward, and allows code reuse between Workers and Windows.
Interoperability and Compatibility Risk
Edge: No signals
Firefox: Intent to ship: https://groups.google.com/d/msg/mozilla.dev.platform/B4F7jCC9jAI/A2c8c7_zBAAJ
Safari: No signals
Ongoing technical constraints
None
Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, Chrome OS, Android, and Android WebView)?
Yes
OWP launch tracking bug
https://bugs.chromium.org/p/chromium/issues/detail?id=690195
Link to entry on the feature dashboard
https://www.chromestatus.com/feature/6491882200760320
Requesting approval to ship?
Yes