Open utterances-bot opened 3 years ago
Thank you for showing us such a simple state management library. I was not aware of jotai and I now feel I should certainly use it in my project. Thanks for a nice article again
Hi Dmitri! I like your post. Wonder if you have any comments or have tried to make a comparison of bundle sizes of most popular global state mgmt libs? That would be very interesting.
Thank you for showing us such a simple state management library. I was not aware of jotai and I now feel I should certainly use it in my project. Thanks for a nice article again
@vipinc007 Thanks! Yes, I like Jotai too for its minimalistic design.
Hi Dmitri! I like your post. Wonder if you have any comments or have tried to make a comparison of bundle sizes of most popular global state mgmt libs? That would be very interesting.
Hi @JacekLab! Good idea about comparing the bundle sizes. I will think about it.
Love your posts. This library seems so easy to use. A bit neater and simpler than useState with Context Provider.
I think I found a typo. In this expression: "const isEvenAtom = atom(get => get(baseAtom) % 2 === 0);". Should baseAtom be replaced with numberAtom?
@phutngo Thanks for letting me know. Fixed.
Actually, Redux's thinking is good, but! It is too heavy, even with redux tookit, its underlying writing is still very heavy. Coupled with its complicated documentation, it is a maze for those who don't use it often. I used Redux a long time ago, and now it feels like a nightmare when I think about it. I think there are many options now, for example Zusand is also a good solution.
@DanaCoding I also think that Redux might be too verbose, but still I think it's a good library. I've heard good things about Zustand too, I should try it. :)
Even so, because Redux is based on Proxy, for many developers, a slight error will cause performance degradation, especially when acting on React-Native. Of course, Zustan is also based on Proxy, so it is best not to use it in key performance code modules. The above is just my personal opinion :)
Very Helpful! Great Post!
A Guide to Jotai: the Minimalist React State Management Library
How to manage global state in React using the minimalist but flexible Jotai library.
https://dmitripavlutin.com/react-jotai-state-management/