Skip to content

Commit 976eed8

Browse files
Update Open Issues Declarative CSS Modules Explainer (#1132)
One of the open issues the [TAG review](w3ctag/design-reviews#1000 (comment)) brought up is regarding import maps: > Was it ever intentional that <script type="importmap"> works inside a shadow root? It'd be good to check with that feature's designers (e.g. @domenic) to ensure that encouraging its use there won't break any assumptions or encourage any footguns. This slipped though the cracks on the last spec update from TAG review feedback, so this PR adds it, nearly verbatim, to the Open Issues section. This also updates language of the other open issue regarding a pending fetch with the same module specifier to prefer to be safer and immediately fail, as we discussed earlier today.
1 parent e7f2d29 commit 976eed8

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

ShadowDOM/explainer.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -770,8 +770,8 @@ The following table compares pros and cons of the various proposals:
770770
771771
## Open issues
772772
* What happens if a `<template shadowrootadoptedstylesheets="">` references a specifier that was imported as a non-inline CSS module whose fetch hasn’t completed yet?
773-
Leading idea: Non-declarative imports don't apply for declarative shadow roots if their status is set to "pending". Alternatively, we could disallow any non-declartive imports on `<template shadowrootadoptedstylesheets="">`.
774-
773+
Leading idea: Disallow any non-declarative imports on `<template shadowrootadoptedstylesheets="">`. This is the simplest approach that will minimize the possibility of an FOUC and non-deterministic behavior based on network timing, at the expense of flexibility. If mixing imperative and declarative CSS modules is a scenario we want to support, an alternative way of handling this case is that non-declarative imports are skipped when processing declarative shadow roots if their status is still "pending" at the time that the declarative shadow root is parsed. Otherwise they are applied in the same way as a declarative import.
774+
* Was it ever intentional that `<script type="importmap">` works inside a shadow root?
775775
776776
## References and acknowledgements
777777
Many thanks for valuable feedback and advice from other contributors:

0 commit comments

Comments
 (0)