Gehören Sie zu den Ersten, denen das gefällt!
Webcamp Zagreb, 2016
React is a great view layer, but what about the rest of the app structure?
React is a great view layer, but if you want to create something more than a simple TODO app, you’ll need some other parts. First of, you’ll need a data structure and a way to handle the changes in it. Although the most simple way to do it could be to take parts of a framework you’re used to (e.g. Backbone Collections/Models), there is something better out there. First, there was the Flux architecture, made by Facebook itself - it forced us to change and consume our data in a certain way in order to prevent developers from shooting themselves in the foot. Then there was Redux - a state container that preaches immutability and time travel. While Redux is great, and enables us great things like hot module reloading, it is also very strict and introduces a lot of boilerplate code. MobX, on the other side, has almost no boilerplate code, can be strict when/if you want it to be, and gives you a nice performance boost for free.