How to use $scope.$Watch and $scope.$Apply in angularjs?
Answer / Kiran Chhabra
$scope.$watch is used to watch for changes in a scope property and execute a function when the watched property changes. $scope.$apply is used to trigger a digest cycle, allowing AngularJS to update the view based on new data or changed properties. It should generally not be necessary to call $scope.$apply manually in most scenarios.
| Is This Answer Correct ? | 0 Yes | 0 No |
How prevents html dom based cross site scripting (xss) attacks?
What is the ngmodule?
Explain system.config.ts file used in angular?
Angular 4 grid with crud operations what is angular router?
What is internationalization and how to implement it in angular js?
What is the difference between lazy loading and eager loading in angular 2?
What is template? Why use? Detail?
How to format a date in angularjs?
What is mobile angular ui?
Is react backend or frontend?
Do you know scope in angular?
Explain the difference between a factory and a service in angularjs?