zerohop.dev
ProThis module is part of zerohop Pro.

HTML Parsing: How a Byte Stream Becomes a DOM

The first module modelled against a browser engine rather than a network stack. Blink's tokenizer decides when to stop by reading the clock — it yields once elapsed time passes the budget it was given, and that budget stretches after the sixth yield, so a long enough document stops being interruptible at all rather than simply taking longer. Meanwhile two different things are called blocking: a classic <script src> stops the token stream, because the script may still call document.write and rewrite the bytes ahead of it, while a stylesheet stops PAINT and is registered as render-blocking only while no <body> element exists yet — which is why moving it into the body buys unstyled content rather than a faster page. Change the parser-blocking script count, the loading strategy, the stylesheet's position, the preload scanner and the document size, and watch the server-computed cascade: how many times the parser yields, how long the longest uninterruptible chunk runs, whether paint is gated or a flash is coming, and the case that reveals the whole system — a head stylesheet promoting an inline script into stopping the parser, a CSS parameter changing a SCRIPT outcome. Validated against Chromium 154.0.8037.57 (PumpTokenizer, IsWaitingForScripts, AddPendingStylesheet, HaveRenderBlockingStylesheetsLoaded, FinishedParsing).

  • All current + future modules
  • Full kata library
  • Progress dashboard + weak area analysis

Cancel anytime. Billed annually.

zerohop.dev — Interactive Network Protocol Simulators