Stop Asking if React Hooks Replace Redux

Max González
The Startup
Published in
6 min readAug 25, 2019

--

Lots of colleagues have been asking me variations of the same question:

“If we’re using hooks in our project, are we going to even need Redux?”

“Don’t React hooks make Redux obsolete? Can’t I just do all the same things Redux does with hooks?”

A quick Google search will show that people are asking these questions all over the internet.

The fast answer to “Do React hooks replace Redux?” is “not really.”

The more nuanced but polite answer is “Well, that really depends on the kind of project you’re working with.”

The answer that I’m inclined to tell people is “I’m not sure you know what you’re talking about.” There are a few reasons why “Do React hooks replace Redux?” is a fundamentally flawed question. To begin with:

Redux is and has always been optional!

According to Dan Abramov (one of the creators of Redux), you might not need Redux. You don’t need to replace something if you don’t need to use it to begin with.

Redux is a JavaScript library, and if you’re working with React (another JavaScript library), React-Redux is yet another JavaScript library you’ll need to import into your app in order to use Redux. Using libraries in your projects adds to your bundle size, which can increase the time it takes your app to load. Because of this, you shouldn’t be using any libraries like jQuery, Redux, MobX (another state…

--

--

Max González
The Startup

Pianist, metalhead, LGBTQ+ rights advocate, and speculative fiction lover who, for some reason, writes about nothing but JavaScript libraries.