This is a cool project to grasp how some of the internals of react-redux work, but please make sure to never do it in production.
For one, this imitates a very old style of Redux and modern Redux would be only a fraction of that code (and a lot more readable).
Also, React-Redux manages subscriptions very differently internally. Context is not suited for this and will lead to performance issues once your state starts growing. For more info on that, see dev.to/javmurillo/react-context-al...
Yes this is not for production just for educational purpose. The reason why I created is when I was learning react. I didn’t understand how redux handle state. Later with the help of context i was able to build on my own. So I thought my learning would help others to understand internal things
Cheers!
This is a cool project to grasp how some of the internals of react-redux work, but please make sure to never do it in production.
For one, this imitates a very old style of Redux and modern Redux would be only a fraction of that code (and a lot more readable).
Also, React-Redux manages subscriptions very differently internally. Context is not suited for this and will lead to performance issues once your state starts growing. For more info on that, see dev.to/javmurillo/react-context-al...
To learn modern Redux, please take a look at the official tutorial: redux.js.org/tutorials/essentials/...
Or for just a quick overview of what changed a few years ago: redux.js.org/tutorials/fundamental...
Yes this is not for production just for educational purpose. The reason why I created is when I was learning react. I didn’t understand how redux handle state. Later with the help of context i was able to build on my own. So I thought my learning would help others to understand internal things
Cheers!
Yup, it's perfectly fine for that :)
With recoil I have everything even cleaner and more organized.