Why we use Redux?

Wooonganthony
Oct 27, 2020

Redux is a JavaScript library that can be injected to React.

Do you know Redux and how it works? Although you did not even use it, it’s fine. Redux is very easy to learn and use.

Am I crazy? No. It’s right. You can learn and use it whenever you can, wherever you can.

Actually, we use Redux for setting global state management.

For a large scale application, we need to set a global state and Redux is very helpful.

By using Redux, we can define 3 main parts — Store, Action, Reducer.

Store — This is a real global state variable

Action — This is an event for updating the store value.

Reducer — This is a module handling how to update the store value.

Redux provides this architecture and we can only use it.

Definitely Redux a set of functions that are based on HOC(High Order Component). With the latest React versions, Redux is also updated and the modern Redux is based on Hook functions, but the main architecture is not changed at all.

Happy Coding… Change your world!!!

--

--