Data-Binding
Data binding is a very useful and powerful feature used in software development technologies. It acts as a bridge between the view and business logic of the application. AngularJS follows Two-Way data binding model.
One-Way Data Binding
The one-way data binding is an approach where a value is taken from the data model and inserted into an HTML element. There is no way to update model from view.
Two-Way Data Binding
Data-binding in Angular apps is the automatic synchronization of data between the model and view components.
<html ><head>
<title>AngularJS Databinding</title>
</head>
<body>
<h2>Sample Application</h2>
<div ng-app="" ng-init="firstName='Ajeet'">
<p>Input something in the input box:</p>
<p>Name: <input type="text" ng-model="firstName"></p>
<p>You wrote: {{ firstName }}</p>
</div>
<script src = "https://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js">
</script>
</body>
</html>