When should you use an attribute versus an element?
Answer / Pankaj Bhardwaj
In AngularJS, elements are used to represent HTML tags and have a fixed structure, while attributes are additional properties that can be added to elements. You should use elements when you want to create an actual HTML tag (such as 'div' or 'input'), and you should use attributes to specify properties or behaviors of the element.
| Is This Answer Correct ? | 0 Yes | 0 No |
On which types of component can we create a custom directive?
Name the key features of angular js?
Why to use “$http” in AngularJS?
Is angular material open source?
How AngularJS handle data binding?
Mention some of the most commonly used directives in angularjs application?
What is $location in angularjs?
What are the binding directives in angularjs?
What is traceur compiler? Why in angular 2?
How you can load external css style?
Explain two-way binding in angularjs?
How do we display errors in a component view with angular 2?