Add the descendants option to ContentChild
See original GitHub issue🚀 feature request
Relevant Package
Description
Similar but opposite to how the ContentChildren
decorator has descendants option to query all descendants, I would like ContentChild
to have an option to query only direct descendants.
Describe the solution you’d like
- Add
descendants
as a metadata property forContentChild
- If
descendants
is true or undefined, query all descendants (preserves current behavior) - If
descendants
is false, query only direct descendants
Issue Analytics
- State:
- Created 4 years ago
- Reactions:11
- Comments:12 (6 by maintainers)
Top Results From Across the Web
ContentChildren - Angular
descendants - If true include all descendants of the element. If false then only query direct children of the element. emitDistinctChangesOnly - The...
Read more >why {descendants: true} doesn't work in ContentChildren?
But purpose of { descendants: true } is used to select descendant children, which means the second MyCustomDirective in componentTwo should also ...
Read more >66. The read & descendants in @ContentChild ... - YouTube
The read & descendants in @ ContentChild & @ ContentChildren are two beneficial options to aid in some complex scenarios. In this 2nd...
Read more >ContentChild and ContentChildren in Angular - TekTutorialsHub
The ContentChild & ContentChildren are decorators, which we use to ... It does not have the static option but has the descendants option...
Read more >Angular - ContentChildren
Any time a child element is added, removed, or moved, the query list will be ... selector - the directive type or the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It would be nice if the bot posted a link to the poll itself. I had no idea where to vote.
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.