Angular · Senior · Question 1 of 75

How does Zone.js let Angular know when to run change detection?

Explanation

Zone.js doesn't know *what* changed, only that some async work completed, so Angular checks the tree from the root (skipping OnPush subtrees that are not dirty). That is simple but can cause many unnecessary checks.

Further reading

Problem with a question

Angular · Senior · question 1

Test yourself

Take the Angular · Senior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz