Skip to content

Commit 77ce3f2

Browse files
committed
Add APIs exposed in ShadowRealms
As discussed in today's meeting, this PR adds the `CustomEvent`, `globalThis.reportError()` and `globalThis.self` APIs to the Minimum Common API. This is done because they will be exposed in ShadowRealms in browsers, and it is useful for code running in ShadowRealms to also be able to run in server-side runtimes.
1 parent d0f9079 commit 77ce3f2

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

index.bs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ Interfaces:
4646
* {{CountQueuingStrategy}}
4747
* {{Crypto}}
4848
* {{CryptoKey}}
49+
* {{CustomEvent}}
4950
* <code class="idl"><a data-link-type="idl" href="https://wicg.github.io/compression/#decompression-stream">DecompressionStream</a></code>
5051
* {{DOMException}}
5152
* {{Event}}
@@ -98,6 +99,15 @@ Global methods / properties:
9899
* globalThis.{{performance}}.{{Performance/now()}}
99100
* globalThis.{{performance}}.{{timeOrigin}}
100101
* globalThis.{{queueMicrotask()}}
102+
* globalThis.{{reportError()}}
103+
* globalThis.self (on {{Window/self|Window}} and {{WorkerGlobalScope/self|WorkerGlobalScope}})
104+
105+
Note: This returns the value of `globalThis`.
106+
107+
Issue: When the <a href="https://github.com/whatwg/html/pull/9893">ShadowRealm integration PR</a>
108+
is merged into the HTML spec,
109+
`self` will also need to be exposed on `ShadowRealmGlobalScope`.
110+
101111
* globalThis.{{setTimeout()}} / globalThis.{{clearTimeout()}}
102112
* globalThis.{{setInterval()}} / globalThis.{{clearInterval()}}
103113
* globalThis.{{structuredClone()}}

0 commit comments

Comments
 (0)