DEV Community

Discussion on: UseReducer React Hook Well Explained

Collapse
 
_ndeyefatoudiop profile image
Ndeye Fatou Diop

Very nice explanation ! I generally use reducer whenever I have a complex state that is passed through the context. In those cases, I can just have two contexts : one that contain the state and another one that contain the updater functions. This is very good for perf improvements

Collapse
 
kpeale profile image
Kpeale Legbara

Thank you very much, Ndeye