Interview Questions

1. When do we use a directive in Angular?

If you create an Angular application where multiple components need to have similar functionalities, you have to do it by adding this functionality individually to every component. This is not a very easy task. Directives are used to cope with this situation. Here, we can create a directive with the required functionality and then import the directive to components that require this functionality.

By Md Riyazuddin 2 0
Is this helpful? Yes No

Submit an interview question

Submitted questions and answers are subject to review and editing, and may or may not be selected for posting, at the sole discretion of w3Sniff.

Get Started

Comments

Leave a Comment


Check out more interview questions

Based on your skills

MS SQL Server

1652591 1720 23 859

Angular

42000 92 0 46

Wordpress

34054 72 1 36