AngularJS > Components

Expressions in AngularJS

What are expressions and how to use it in AngularJS?


Expression in AngularJS is javascript like code that is placed in bindings to insert dynamic values into the html pages. It starts with  "{{" and ends with "}}".

<div ng-app>
<h2>Expressions in AngularJS</h2>
The sum of 2 + 5 is <strong>{{2 + 5}}</strong>.
</div>

The above code will show 7 in bold ie the addition of 2 and 5.

 Views: 12873 | Post Order: 8




Write for us






Hosting Recommendations