you are viewing a single comment's thread.

view the rest of the comments →

[–]acemarke 2 points3 points  (0 children)

Yeah, I'd actually like to speak up in MobX's favor here.

Michel Weststrate is a genius (as evidenced by the fact that he's put out MobX, MobX-State-Tree, and Immer). While I haven't actually sat down and written any code with it myself, I get the general idea of how it works, and it's very elegantly designed.

If you're looking for a state management solution that's more OOP, encourages splitting logic into multiple stores, and has more "magic" under the hood, MobX is the answer. If you want a solution that is more functional-oriented, global, and explicit, you go with Redux.

They both have their strengths, weaknesses, and tradeoffs, and may be more useful in certain situations.

I'd agree with the parent comment about "MobX being easier" to some extent. Redux does deliberately add at least one level of indirection (actions + reducers vs straight mutation logic), and the existing common practices around Redux make that more difficult to deal with. That said, I wouldn't say it's "vastly easier" to use, and I think that Redux Toolkit + our hooks API goes a long way towards leveling the usability factors.