Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Be clearer about documents in script execution #7842

Merged
merged 1 commit into from Apr 26, 2022
Merged

Conversation

domenic
Copy link
Member

@domenic domenic commented Apr 21, 2022

The only normative change here is to delay the load event of the script's preparation-time document, instead of its node document (which could change while the fetching is in progress). Closes #5160.

Otherwise, this consists of cleanups to use more precise language for certain documents, thus closing #7589, and of the pending parsing-blocking script concept to use more imperative language.

@hiroshige-g feel free to review (but doing so is optional).

(See WHATWG Working Mode: Changes for more details.)


/dynamic-markup-insertion.html ( diff )
/parsing.html ( diff )
/scripting.html ( diff )
/xhtml.html ( diff )

The only normative change here is to delay the load event of the script's preparation-time document, instead of its node document (which could change while the fetching is in progress). Closes #5160.

Otherwise, this consists of cleanups to use more precise language for certain documents, thus closing #7589, and of the pending parsing-blocking script concept to use more imperative language.
@hiroshige-g
Copy link
Contributor

LGTM, thank you!

<p id="scriptTagParserResumes">At this stage, if there is a <span>pending parsing-blocking
script</span>, then:</p>
<p id="scriptTagParserResumes">At this stage, if the <span>pending parsing-blocking
script</span> is not null, then:</p>
Copy link
Member

Choose a reason for hiding this comment

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

From this point on the member is grabbed out of thin air again. Can that be fixed as well or is this part trickier?

Copy link
Member Author

Choose a reason for hiding this comment

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

This is part of the parser, which seems to operate on ambient "parser" and "document" variables without ever really defining them (or their relationship). That should probably be done in a future overhaul.

@domenic domenic merged commit 60a9ea1 into main Apr 26, 2022
@domenic domenic deleted the script-documents branch April 26, 2022 17:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

Which Document do <script>s delay the load events of?
3 participants