$watch control

Kmandapalli
Posted by Kmandapalli under AngularJS category on | Points: 40 | Views : 269
angular.module('MyFirstModule',[]).controller('MyFirstController',function($scope){    
$scope.salary='25000';

$scope.$watch('salary',function(newSalary,oldSalary){
console.log("There has been change in your salary");
}
});

Comments or Responses

Login to post response