July 2018
Beginner
236 pages
5h 34m
English
The utility that acts as the counterpart of intercept() is observe(). observe(), as the name suggests, allows you to make granular observations on observables:
The signature is exactly like intercept(), but the behavior is quite different. observe() is invoked after the change has been applied to the observable.
An interesting characteristic is that observe() is immune to transactions. What this means is that the observer callback is invoked immediately after a mutation and does not wait until the transaction completes. As you are aware, actions are the places where a mutation happens. MobX optimizes the notifications by firing them, but only after the top-most ...
Read now
Unlock full access