My Blog Posts

What is MobX?

What is MobX?


MobX is available with any JavaScript frame state management library. React and MobX together are powerful and complete works as a frame. To create the component of MobX, React Native provides a mechanism for storing and updating the application state it uses. 

MobX has two main principles:

1. One-Way Data Flow (If Requested Flux)

2. Reactive

One-Way Stream :

First of all, MobX is a freamwork based on "Flux" does not claim. MobX has not been described as freamwork author and JS developer, however, autonomy in the structure of the data in the application Has. To make a user's app better, MobX tools and plug-ins that can be used.

For example, from Redux (another popular state administration freamwork) differently, it does not require the launch of a store. However, if prompted, a can be made in grain.

Three features of MobX's functionality include:

Observable: Data tracked and used in the application (or state). There can be almost any type of data structure, and it is usually updated by the 

Observer: Link between componens and observable Establishes. Updates the linked code when updated and makes them automatic.

Update Action: State.


Reactive:

MobX is simply not based on data, but by data usage. To disrupt this expression, you can use the code to be to have separate code contexts that communicate with each other through linking there is a difference between the two.

When data is connected as a chain, each piece of code and reacts to each other by default. It's like a chain It's like shaking. Other case management frameworks, such as Redux, @connect function manual subscribers. This allows the developer to requires that it manually add the data it is connected to. So that the contexts to "communicate" with each other.

Think of each "connection" in the chain as a component. MobX encourages the use of component as much as possible. It's philosophy. It's different from React and Redux. Less componetin at a smaller level, Redux it is true that it performs less than others, but  Unlike scale, MobX is more performance compared to the scale.

 



Share this article


Comments (0)

Comment