DEV Community

Discussion on: Redux or Context API?

Collapse
 
kirillvy profile image
Kirill V

Depends on what you're doing. If you're going on an existing project, it's pretty much guaranteed to have Redux. Context API is good for fairly small apps with few asynchronous actions and dependencies. You also have to keep track of your state structure in both cases.

If you're starting something new and potentially big, you may want to learn about Effector, which gives you both a hooks-based state API and an event bus to tie together different states, as well as subscriptions to asynchronous events ('effects'). As a warning, it's currently not fully documented, so you have to jump between the docs and the GitHub readme to use it effectively.