Skip to content

Conversation

@andreubotella
Copy link
Member

Here's the relevant feedback:

  • The standard assumes that Window exists in the global scope ("The global object on Window-like and worker environments should always be an instance"). However, it does not include Window in section 5 (Common API Index).

  • The text on the Worker global scope omits the worker global postmessage. But, it also does not mention that workers are obliged to include some, but not all, of the other properties of the global scope. What about importScript? Further, the text implies Worker support is optional ("If a web-interoperable runtime supports workers") – is it? My guess is it is required but that a runtime can document that deviation if it is unsupported. The text is ambiguous.

@andreubotella andreubotella marked this pull request as ready for review November 18, 2025 05:38
Copy link
Contributor

@jasnell jasnell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with caveats. I'm happy with this going forward as is but would prefer the workers link to be added at least.

@andreubotella andreubotella merged commit 9b4e751 into main Nov 19, 2025
5 checks passed
@andreubotella andreubotella deleted the global-scope-clarifications branch November 19, 2025 04:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants