Skip to content

fix(core): restore projection into recreated hydration nodes - #72233

Open
ietuday wants to merge 2 commits into
angular:mainfrom
ietuday:fix/72132-hydration-projected-content
Open

ietuday wants to merge 2 commits into
angular:mainfrom
ietuday:fix/72132-hydration-projected-content

Conversation

@ietuday

@ietuday ietuday commented Nov 26, 2026 •

Copy link
Copy Markdown

PR Checklist

PR Type

  • Bugfix
  • Feature
  • Code style update
  • Refactoring
  • Build related changes
  • CI related changes
  • Documentation content changes
  • angular.dev application / infrastructure changes
  • Other

What is the current behavior?

During hydration, Angular skips inserting projected content when hydration information exists on the view, even if the parent element was recreated on the client.

As a result, nested projected content remains missing when a previously hidden container becomes visible after hydration.

Issue Number: #72132

What is the new behavior?

The projection instruction now checks whether the parent node can be hydrated before skipping content insertion.

Regression tests have been added to cover:

  • Initially hidden and visible server-rendered content.
  • Nested projected elements.
  • Repeated hide/show operations.
  • Existing hydration behavior and duplicate element checks.

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

Thanks to @floxcristian for the detailed reproduction, root-cause analysis and proposed solution.

Based on the reproduction and proposed fix by @floxcristian in angular#72132. AI-assisted implementation.
Regression coverage for angular#72132, based on @floxcristian's reproduction. AI-assisted.
@google-cla

google-cla Bot commented Nov 26, 2026

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@pullapprove
pullapprove Bot requested a review from kirjs November 26, 2026 22:39
@angular-robot angular-robot Bot added the area: core Issues related to the framework runtime label Nov 26, 2026
@ngbot ngbot Bot added this to the Backlog milestone Nov 26, 2026
@google-cla google-cla Bot added cla: yes and removed cla: no labels Nov 26, 2026
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 framework runtime cla: yes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants