in Angular by
If your data model is updated outside the ‘Zone’, explain the process how will you the view?

1 Answer

0 votes
by

You can update your view using any of the following:

ApplicationRef.prototype.tick(): It will perform change detection on the complete component tree.

NgZone.prototype.run(): It will perform the change detection on the entire component tree. Here, the run() under the hood will call the tick itself and then parameter will take the function before tick and executes it.

ChangeDetectorRef.prototype.detectChanges(): It will launch the change detection on the current component and its children.

Related questions

0 votes
asked Jun 16 in MemCached by Robindeniel
+1 vote
asked Jan 24, 2020 in Data Science by AdilsonLima
0 votes
asked Nov 21, 2021 in MongoDB by DavidAnderson
...