Q. Which directive is used to conditionally include an element in Angular templates?

  • (A) *ngIf
  • (B) *ngFor
  • (C) *ngSwitch
  • (D) *ngInclude
πŸ’¬ Discuss
βœ… Correct Answer: (A) *ngIf
Explanation: *ngIf is used to include or exclude an element conditionally in the template.
Explanation by: Mr. Dubey
*ngIf is used to include or exclude an element conditionally in the template.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
87
Total Visits
πŸ“½οΈ
1 y ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
83%
Success Rate