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

HTML parser doesn't tell when it should suspend and resume #10406

Open
dSalieri opened this issue Jun 11, 2024 · 0 comments
Open

HTML parser doesn't tell when it should suspend and resume #10406

dSalieri opened this issue Jun 11, 2024 · 0 comments
Labels
clarification Standard could be clearer topic: parser

Comments

@dSalieri
Copy link

What is the issue with the HTML Standard?

Reading about HTML parser, I came to the conclusion that the specification does not talk about:

  1. Should the HTML parser task be suspended if the input stream is temporarily empty (not EOF case)
  2. Is it necessary to suspend the HTML parser task if the input stream has a lot of data. Is it preferable to parse data in chunks?

For example, chrome and firefox handle the second case differently.

Chrome suspends parsing task when character processing reaches a certain limit (page will be updated several times). Firefox, on the contrary, analyzes the data to the end and does not make any suspends (the page will be updated once during the HTML parsing process).

The complaint about the specification is this:
Why is there no preferred behavior, or, as a last resort, a note that would describe cases above and mark them as implementation-dependent.

@annevk annevk added clarification Standard could be clearer topic: parser labels Jun 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clarification Standard could be clearer topic: parser
Development

No branches or pull requests

2 participants