lit/lit

[labs/ssr] Remove deprecated `shadowroot` attribute from emitted DSD

Open

#4,352 opened on Nov 1, 2023

View on GitHub
 (5 comments) (0 reactions) (0 assignees)TypeScript (874 forks)batch import
Contributions WelcomeGood First Issue

Repository metrics

Stars
 (16,966 stars)
PR merge metrics
 (Avg merge 8d 10h) (3 merged PRs in 30d)

Description

Should this be an RFC?

  • This is not a substantial change

Which package is this a feature request for?

SSR (@lit-labs/ssr)

Description

Currently we include both the old shadowroot attribute and the new shadowrootmode attribute on <template> elements of the generated DSD.

Chromium was the only one that was supporting the shadowroot attribute. It began shipping streaming DSD with the new shadowrootmode attribute in Chromium 111 along with Webkit early this year. https://chromestatus.com/feature/5161240576393216 https://bugs.webkit.org/show_bug.cgi?id=249513

The non-standard shadowroot attribute has been marked deprecated since Chromium 112, to be removed in Chromium 119. https://chromestatus.com/feature/6239658726391808

The template shadowroot ponyfill was already updated to look for shadowrootmode instead of shadowroot here https://github.com/webcomponents/template-shadowroot/pull/43

Alternatives and Workarounds

n/a

Contributor guide