Re: [whatwg/dom] Proposal: DOM APIs in web workers? (Issue #1217)

Enjoyed reading this thread. This is a great question:

> what problem are we trying to solve

For me, it simply boils down to having a standard way to _parse_ HTML _without_ "the DOM ™️". I think it gets tricky when communicating this because, traditionally, what we're parsing from (static HTML) is of course tightly coupled with the representation that we're parsing into (the DOM) and of course all the baggage that comes with. 

That's why I like where @BenjaminAster's hint at representing the DOM without it actually being @surma's "DOM ™️" 😄. That's where @bahrus's suggestion of looking at Cloudflare's contribution with [HTMLRewriter](https://developers.cloudflare.com/workers/runtime-apis/html-rewriter) comes into play. From what I can tell, it also represents it's own DOM, so to speak, without it of course being a full on representation (with event listeners and etc, as noted above).

I think of it as an intermediate still-mostly-serialized state. It's not HTML anymore but it's also not "the DOM ™️" per se, either.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/dom/issues/1217#issuecomment-1968157085
You are receiving this because you are subscribed to this thread.

Message ID: <whatwg/dom/issues/1217/1968157085@github.com>

Received on Wednesday, 28 February 2024 03:39:17 UTC