AngularJS Developer Question:
Download Questions PDF

Tell me when should you use an attribute versus an element?


Use an element when you are creating a component that is in control of the template. Use an attribute when you are decorating an existing element with new functionality.

This topic is important so developers can understand the several ways a directive can be used inside a view and when to use each way.

Download AngularJS Developer Interview Questions And Answers PDF

Previous QuestionNext Question
What is ng-disabled directive?Explain me what is injector?