AngularJS Question:
Download Job Interview Questions and Answers PDF
How to initiate variable in AngularJS?
Answer:
1 <div ng-app="" ng-init="quantity=10;cost=5">
2 <b>Total Cost: {{ quantity * cost }}</b>
3 </div>
2 <b>Total Cost: {{ quantity * cost }}</b>
3 </div>
Download AngularJS Interview Questions And Answers
PDF
Previous Question | Next Question |
What is Data Binding in Angular JS? | Does Angular use the jQuery library? |