Skip to content

fix(runtime): stop forwarded named slot being added to nested default slot - #6815

Merged
johnjenkins merged 2 commits into
mainfrom
fix-named-slot-forwarding
Aug 8, 2026
Merged

fix(runtime): stop forwarded named slot being added to nested default slot#6815
johnjenkins merged 2 commits into
mainfrom
fix-named-slot-forwarding

Conversation

@johnjenkins

@johnjenkins johnjenkins commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

What is the current behavior?

GitHub Issue Number: #6770

A non-shadow slot optimisation piece of work I did (a while ago) uncovered a bug that was hidden by the (now removed) experimentalSlotFixes flag; forwarded <slot name="thing"> would be 'grabbed' by the nested component and added to it's default slot

What is the new behavior?

Fixes #6770

We now more accurately detect incoming forwarded <slot> nodes and make sure they're not automatically grabbed by the nested child's default slot.

Tested against the linked repro

Note - this fix uncovered that stencil non-slot forwarding does not match native behaviour. V5 (via #6814) will correctly fix the overall forwarding behaviour - it was deemed to large a behaviour change for v4

Documentation

Does this introduce a breaking change?

  • Yes
  • No

Testing

Other information

@johnjenkins
johnjenkins requested a review from a team as a code owner August 8, 2026 21:27
@johnjenkins
johnjenkins merged commit b493d61 into main Aug 8, 2026
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: non-shadow component named slot forwarding puts content to default slot instead

1 participant