Redux Pattern and Next.js


Next.js

Updated Jun 28th, 2021

Article here on old way

It’s my understanding of the Redux pattern is different than the third-party state management library called Redux

The Redux pattern leverages useReducer and maybe even useImmerReducer and I’m not sure how it works with next.js

This article makes it seem possible

Good video by Lee on global state to get around prop drilling and the implications with next JS here. In this article he talks about the fact that the reacts built in context API is really not a state management tool until you combine it with used state or use reducer. So clearly you can use use reducer. He also mentions that Immer just allows you to write code in a mutable fashion that produces an immutable result. All this points to the fact that we could implement the react for the rest of us project, including useImmerReducer, in next.js