develwoutacause’s avatardevelwoutacause’s Twitter Archive—№ 1,731

          1. I had no idea you could stream HTML via userspace JS! I need to update my HTML fragments demo to stream the content directly into the document... blog.dwac.dev/posts/html-fragments/ @jaffathecake/1564632587980644359
        1. …in reply to @develwoutacause
          I got some time to try this out, and unfortunately it's not compatible with declarative shadow DOM which completely breaks my demo app 😭. In theory, I guess you could do a streaming parse like this with a userspace HTML parser, not sure if one exists for browser JS.
      1. …in reply to @develwoutacause
        I can literally *touch* the line the code which would enable declarative shadow DOM with document.implementation.createHTMLDocument. source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/dom/dom_implementation.cc;l=108;drc=fde2db9853cab5681586ea71d877f4cefd5eee13
    1. …in reply to @develwoutacause
      Looks like we might be blocked on decisions in github.com/whatwg/dom/issues/912, though createHTMLDocument hasn't had much specific discussion. @jaffathecake @_developit @Mfreed777, is there enough consensus on this particular flag that I could contribute it to Chrome? 😉
  1. …in reply to @develwoutacause
    Finally got something working though I needed quite a few hacks to make declarative shadow DOM work. I wrote down some details and learnings from the experience. @develwoutacause/1573688712059359232?s=20&t=SsRXtK8wPpdDjvawy1RrNQ
    1. …in reply to @develwoutacause
      Ironically I probably couldn't have used native DSD support for createHTMLDocument anyways because shadow roots can't be cloned across documents, and that's a major challenge I had to overcome in the process.