Skip to content

fix(compiler): ng-template directive invoke twice at the root of control flow#52515

Closed
crisbeto wants to merge 1 commit intoangular:mainfrom
crisbeto:control-flow-projection-template
Closed

fix(compiler): ng-template directive invoke twice at the root of control flow#52515
crisbeto wants to merge 1 commit intoangular:mainfrom
crisbeto:control-flow-projection-template

Conversation

@crisbeto
Copy link
Member

@crisbeto crisbeto commented Nov 5, 2023

Discovered this while validating #52414 against Angular Material. We were projecting <ng-template> nodes at the root of @if and @for with the ng-template tag name which enables directive matching and applies the directive to the control flow node.

These changes fix the issue by never passing along the ng-template tag name.

…rol flow

Discovered this while validating angular#52414 against Angular Material. We were projecting `<ng-template>` nodes at the root of `@if` and `@for` with the `ng-template` tag name which enables directive matching and applies the directive to the control flow node.

These changes fix the issue by never passing along the `ng-template` tag name.
@crisbeto crisbeto marked this pull request as ready for review November 5, 2023 09:20
@crisbeto crisbeto added action: review The PR is still awaiting reviews from at least one requested reviewer area: compiler Issues related to `ngc`, Angular's template compiler target: rc This PR is targeted for the next release-candidate labels Nov 5, 2023
@crisbeto crisbeto added this to the v17-final milestone Nov 5, 2023
@dylhunn dylhunn self-requested a review November 6, 2023 14:53
Copy link
Contributor

@dylhunn dylhunn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense, and thanks for also fixing template pipeline!

@crisbeto crisbeto removed the request for review from pkozlowski-opensource November 6, 2023 15:03
@crisbeto crisbeto added action: merge The PR is ready for merge by the caretaker and removed action: review The PR is still awaiting reviews from at least one requested reviewer labels Nov 6, 2023
@atscott
Copy link
Contributor

atscott commented Nov 6, 2023

This PR was merged into the repository by commit 9cfd35a.

@atscott atscott closed this in 9cfd35a Nov 6, 2023
atscott pushed a commit that referenced this pull request Nov 6, 2023
…rol flow (#52515)

Discovered this while validating #52414 against Angular Material. We were projecting `<ng-template>` nodes at the root of `@if` and `@for` with the `ng-template` tag name which enables directive matching and applies the directive to the control flow node.

These changes fix the issue by never passing along the `ng-template` tag name.

PR Close #52515
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Dec 7, 2023
ChellappanRajan pushed a commit to ChellappanRajan/angular that referenced this pull request Jan 23, 2024
…rol flow (angular#52515)

Discovered this while validating angular#52414 against Angular Material. We were projecting `<ng-template>` nodes at the root of `@if` and `@for` with the `ng-template` tag name which enables directive matching and applies the directive to the control flow node.

These changes fix the issue by never passing along the `ng-template` tag name.

PR Close angular#52515
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: merge The PR is ready for merge by the caretaker area: compiler Issues related to `ngc`, Angular's template compiler target: rc This PR is targeted for the next release-candidate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants