- From: Steve Orvell <notifications@github.com>
- Date: Wed, 18 Dec 2024 08:45:41 -0800
- To: whatwg/dom <dom@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Wednesday, 18 December 2024 16:45:44 UTC
The common case here is definitely legacy code that does `template.content.cloneNode(true)` so if those are null and become the insertion registry, this makes sense. **Implementation concern:** My understanding is that there's a strong desire to avoid initializing the `customElements` getter in the common case, but if it default to `window.customElements` but in the template cloning case it would be `null`, that has to be initialized. I think this is a very common way frameworks create DOM. For cross-document un-upgraded nodes with a customElements set, my concern is that generally these elements have their backing class changed to the adopting document's `HTMLElement` so either this has to be accounted for or they would fail to upgrade in *any* registry from their initial document. Perhaps all un-upgraded elements should have their registry set to `null` on adoption? -- Reply to this email directly or view it on GitHub: https://github.com/whatwg/dom/issues/1339#issuecomment-2551808762 You are receiving this because you are subscribed to this thread. Message ID: <whatwg/dom/issues/1339/2551808762@github.com>
Received on Wednesday, 18 December 2024 16:45:44 UTC