3 ms·
In my experience with MobX, reactions that mutate observables (which triggers other reactions) can quickly get out of hand and become hard to debug if you're no
by brundolf 6y ago
In my experience with MobX, reactions that mutate observables (which triggers other reactions) can quickly get out of hand and become hard to debug if you're not careful.
But doing this is also a huge code smell, and expressly stated as such in the docs, and even though it's necessary every once in a while, it's very possible to keep it under control to where it doesn't become a problem even in quite large projects.
- Gehinnn 6y agoWe put a facade on top of mobx that requires every autorun, reaction and runInAction to be named. Of course, updates outside of transactions are forbidden. This makes even complex applications debuggable!
- machiaweliczny 6y agoThat's why it should be forbidden by default. But if you use 1 way flow (events -> store -> ui) then MobX is great.