Skip to content

Answer:58#1263

Closed
tsironis13 wants to merge 4 commits intotomalaforge:mainfrom
tsironis13:angular-content-projection-condition-challenge
Closed

Answer:58#1263
tsironis13 wants to merge 4 commits intotomalaforge:mainfrom
tsironis13:angular-content-projection-condition-challenge

Conversation

@tsironis13
Copy link
Copy Markdown
Contributor

The solution is based on the fact that we cannot include 2 ng-content tags with the same selector. This is an Angular by design constraint. Ng-template tag can be used instead.

@github-actions github-actions Bot added 58 ng-content condition answer answer contributor highly contributing to the project to be reviewed PR requests a review labels Mar 27, 2025
@Directive({
selector: '[appCardMessage]',
})
export class CardMessageDirective {}
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

nice, using a directive to avoid magic string is the cherry on top. Nice solution

@tomalaforge tomalaforge removed the to be reviewed PR requests a review label Mar 28, 2025
@github-actions
Copy link
Copy Markdown

This pull request is stale because it has been open for 15 days with no activity.

@github-actions github-actions Bot added the stale label Apr 18, 2025
@github-actions
Copy link
Copy Markdown

This pull request was closed because it has been inactive for 5 days since being marked as stale.

@github-actions github-actions Bot closed this Apr 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

58 ng-content condition answer answer contributor highly contributing to the project stale

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants