DEV Community


Discussion on: useReducer instead of useState while calling APIs!

spyda247 profile image
Babajide Ibiayo

Excellent Article...thanks for sharing.

I noticed you dispatched a action of type ACTIONS.SUCCESS in the event of an Error response status. Is this a typo?

ms_yogii profile image
Yogini Bende Author

Good catch! It was a type.. fixed it 😇
Thank you 🙌

Some comments have been hidden by the post's author - find out more

Forem Open with the Forem app