3 ms·
What does that have to do with redux? How does it replace a client side state management solution?
by searchableguy 6y ago
What does that have to do with redux?
How does it replace a client side state management solution?
- hesarenu 6y agoI have used react-query which does the same thing. The server responses can be cached like a redux store. The same query can then be reused elsewhere. You have setting to not cache at all, cache for some time or cache infinity. I have used it on redux project and replaced many with react-query. It does feel better for server data. Not much boilerplate.
- cjr 6y agoDepends on your approach but for me most state in redux was remote data which SWR now caches for me. Other shared local state, such as which project a user is currently viewing, just goes into react context. This removed so much boilerplate for me, adding new calls to the backend is now much simpler.