From 5bd00504bc0e7925591b6b05ee95644be38dd5e2 Mon Sep 17 00:00:00 2001 From: Anne van Kesteren Date: Sat, 4 Oct 2025 12:11:13 +0200 Subject: [PATCH] Make attachShadow() use the global registry by default This significantly improves the reuse of custom elements in different registries. Tests: https://github.com/web-platform-tests/wpt/pull/55248. Fixes #1407. --- dom.bs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dom.bs b/dom.bs index e61c3fc0..a940d13c 100644 --- a/dom.bs +++ b/dom.bs @@ -7583,7 +7583,8 @@ are:

The attachShadow(init) method steps are:

    -
  1. Let registry be this's custom element registry. +

  2. Let registry be this's node document's + custom element registry.

  3. If init["{{ShadowRootInit/customElementRegistry}}"] is non-null: