AngularJS

Expressions of AngularJS

Share

In AngularJS, To bind application data to html expressions are used. It is written inside of double braces like {{expression}}. It uses same way as ng-bind.

Following example will show all the expressions of AngularJS:

<html>
<title>My AngularJS Expressions</title>
<body>
<h1>AngularJS Expressions</h1>
<div ng-app="" ng-init="quantity=2;cost=10; colleague={firstname:'Tim',lastname:'Ererld',salary:25000};Points=[10,20,30,40,50]">
<p>Welcome {{colleague.firstname + " " + colleague.lastname}}!</p>
<p>Price(Rs) : {{quantity * cost}}</p>
<p>Salary: {{colleague.salary}}</p>
<p>Points: {{Points[3]}}</p>
</div>
<script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.3.14/angular.min.js"></script>
</body>
</html>

Recent Posts

Unlock Growth – Guide to Online Financing and Business Loans for Entrepreneurs

If you are in a financial crisis , or need to start a new business…

21 hours ago

Optimize Your Hormonal Balance: Enclomiphene Citrate for Enhanced Wellness

Hormonal balance plays a pivotal role in overall well-being, influencing various aspects of health, from…

2 days ago

Paul Kanes Explores the World of Canine Companionship through Dog Walking

Dog walking is an excellent way to maintain your furry friend's camaraderie and provides many…

2 days ago

Top 5 Must-Have Features Every Mobile App Needs to Succeed

Introduction Businesses understand the diverse requirements of mobile applications, which provide a competitive advantage. There…

2 days ago

IoT Data Analytics: Ways to Gain Value from IoT Data

The Internet of Things (IoT) has recently changed the world. It links gadgets together and…

2 days ago

The Rise of NFTs: Exploring the Impact of Non-Fungible Tokens on the Digital Economy

NFTs, or Non-Fungible Tokens, are revolutionizing the digital economy. These unique digital assets, authenticated through…

3 days ago