What is the difference between $watch and $observe?
Answer / chaitanya
$watch is a method on the scope object which is used to watch expressions. The expression can be either strings or functions.
$observe is a method on the attrs object which is only used to observe the value change of a DOM attribute. It is only used inside directives.
Is This Answer Correct ? | 2 Yes | 0 No |
When should we use angular?
Is typescript an oop?
What is $injector and $inject?
What is attribute directive in angular?
What are zones? What is change detection?
What are the data bindings m angular?
What is lazy loading in angular?
What are the difference between angular 4 & angular 5?
How to use angular datepicker in angular 5/4 applications?
What is the main purpose of find index in angularjs?
What is primitive data type?
Does typescript have a future?