What is use for TemplateRef in Angular?
Answers
Answered by
0
You can access a TemplateRef, in two ways. Via a directive placed on a <ng-template> element (or directive prefixed with *) and have the TemplateRef for this Embedded View injected into the constructor of the directive using the TemplateRef Token. Alternatively you can query for the TemplateRef from a Component or a Directive via Query.
Hope it helps u
Hope it helps u
Similar questions