Better Programming

Advice for programmers.

Follow publication

Member-only story

10 Easy Steps To Abandon Redux for the Remarkable React Hooks

Martin Novak
Better Programming
Published in
11 min readAug 3, 2021
Cartoon turtle: “I don’t always replace Redux, but when I do replace Redux… I just write another Redux, muhahaha!”
Original artwork by the author.

If you are developing a React application, the most simple way of managing your global state and access to your backend is through React Hooks.

Even though there have been a lot of articles talking about hooks since they were released in React 16.8, it is actually hard to find a guide that explains well how to leverage them to architecture your application.

I will give you the best scalable approach to manage sharing data across your application and working with your backend APIs through React hooks that I am using in all my React apps.

If you are already familiar with Redux, then my solution should feel very similar with just a few small differences. We will develop simple middleware for global scope, and we will manage all API calls with axios.

Final API: Keeping Components Clean And Simple

Create an account to read the full story.

The author made this story available to Medium members only.
If you’re new to Medium, create a new account to read this story on us.

Or, continue in mobile web

Already have an account? Sign in

Martin Novak
Martin Novak

Written by Martin Novak

Martin is a product manager at work, a software developer in his free time, and an entrepreneur at heart.

Write a response