On Tue, Feb 23, 2021 at 5:06 PM Mason Freed via webkit-dev < webkit-dev@lists.webkit.org> wrote:
On Fri Feb 19 20:36:12 PST 2021 Ryosuke Niwa via webkit-dev < webkit-dev at lists.webkit.org> wrote:
I replied in the issues directly so that people outside of the WebKit community can follow the discussion.
Thanks! I've replied there also.
The issue with the semantics of getInnerHTML is problematic enough that we'd object to this feature as long as that's included in its current shape.
How does one specify a declarative shadow root to use a specific custom
element registry?
Well, I do see this as something that is better designed as part of the scoped custom element registry proposal. But the basic idea would be to just to add an attribute that allows the declarative shadow root to opt out of automatically using the global registry:
<template shadowroot=open scoped-registry>
and that would keep any custom elements contained within the shadow root from automatically upgrading based on the global registry. Maybe by just assigning an empty custom registry to that shadow root. We'll need to add an attribute to ShadowRoot, as part of the SCER proposal, to allow custom elements to then set the appropriate custom registry later.
That seems to indicate that none of the custom elements inside a declarative shadow root can be upgraded until all its ancestor custom elements which use a custom element registry have been upgraded. This would make the declarative shadow DOM's perf benefit less attractive IMO. - R. Niwa