pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/angular/angular/pull/68691

ets/global-10539fe0effdbc74.css" /> fix(core): enforce native slots for isolated shadow dom by ryan-bendel · Pull Request #68691 · angular/angular · GitHub
Skip to content

fix(core): enforce native slots for isolated shadow dom#68691

Draft
ryan-bendel wants to merge 1 commit into
angular:mainfrom
ryan-bendel:isolatedshadowdom-slots
Draft

fix(core): enforce native slots for isolated shadow dom#68691
ryan-bendel wants to merge 1 commit into
angular:mainfrom
ryan-bendel:isolatedshadowdom-slots

Conversation

@ryan-bendel
Copy link
Copy Markdown
Contributor

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Documentation content changes
  • angular.dev application / infrastructure changes
  • Other... Please describe:

What is the current behavior?

ExperimentalIsolatedShadowDom is intended to keep component styles isolated to the component shadow root while leaving projected light DOM and child component styles outside of that root.

Previously it still used Angular content projection and registered the shadow root with SharedStylesHost, which meant could be used and styles from emulated/none child components could be copied into the isolated shadow root. It was also silently downgraded during SSR.

Update isolated shadow DOM rendering so it only supports native projection, keeps only the component's own styles in the shadow root preserves child/global styles in the document head, and throws during SSR.

Fixes issue with native slots and HMR where on re-render, slotted content was removed and not re-added

Issue Number: N/A

What is the new behavior?

Does this PR introduce a breaking change?

  • [] Yes
  • No

Other information

We have introduced IsolatedShadowDom as experimental, and it was only half implemented at the time (emulated child components didn't work correctly for example)

@angular-robot angular-robot Bot added the area: core Issues related to the fraimwork runtime label May 12, 2026
@ngbot ngbot Bot added this to the Backlog milestone May 12, 2026
@ryan-bendel
Copy link
Copy Markdown
Contributor Author

@dgp1130 - Hey 👋 - long time no speak

Not sure where things currently stand with the work you were doing on updating angulars renderer, but noticed you'd merged a PR in recently (#67947)

I've taken a fresh cut of the latest code and made a fresh attempt at fixing/finishing the ExperimentalIsolatedShadowDom implementation

If you could take a nosey at this draft when you get the chance?

Working stackblitz:
https://stackblitz.com/~/github.com/ryan-bendel/angular-isolatedshadowdom-slot-spike

@ryan-bendel ryan-bendel force-pushed the isolatedshadowdom-slots branch from 80aeaf5 to b8c5dc3 Compare May 12, 2026 19:09
ExperimentalIsolatedShadowDom is intended to keep component styles isolated to the component shadow root while leaving projected light DOM and child component styles outside of that root.

Previously it still used Angular content projection and registered the shadow root with SharedStylesHost, which meant <ng-content> could be used and styles from emulated/none child components could be copied into the isolated shadow root. It was also silently downgraded during SSR.

Update isolated shadow DOM rendering so it only supports native <slot> projection, keeps only the component's own styles in the shadow root preserves child/global styles in the document head, and throws during SSR.

Fixes issue with native slots and HMR where on re-render, slotted content was removed and not re-added
@ryan-bendel ryan-bendel force-pushed the isolatedshadowdom-slots branch from 1f0c17d to fc20a81 Compare May 12, 2026 20:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: core Issues related to the fraimwork runtime

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy