Hey, thanks so much for this tutorial. It's almost complete...
I was wondering why the console.log("redux -> ", action.payload.data.test) line never fired to change "Hello World" to "Saga Data". I think you're actually missing the step where you connect your saga as middleware when setting up the redux store.
Ctrl-F "To run our Saga, we'll have to connect it to the Redux Store using the redux-saga middleware."
One more thing - for those of us who learned to use Redux by explicitly calling dispatch() on an action, you may want to explain that you are using the Object shorthand form of mapDispatchToProps to initially dispatch getDataRequest. I had some trouble figuring out why this action was actually dispatching in componentDidMount despite the fact that I never explicitly "dispatched" it in the code.
Otherwise, helpful tut! Thanks for taking the time to write this up!
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Hey, thanks so much for this tutorial. It's almost complete...
I was wondering why the
console.log("redux -> ", action.payload.data.test)
line never fired to change "Hello World" to "Saga Data". I think you're actually missing the step where you connect your saga as middleware when setting up the redux store.redux-saga.js.org/
Ctrl-F "To run our Saga, we'll have to connect it to the Redux Store using the redux-saga middleware."
One more thing - for those of us who learned to use Redux by explicitly calling
dispatch()
on an action, you may want to explain that you are using the Object shorthand form ofmapDispatchToProps
to initially dispatchgetDataRequest
. I had some trouble figuring out why this action was actually dispatching incomponentDidMount
despite the fact that I never explicitly "dispatched" it in the code.Otherwise, helpful tut! Thanks for taking the time to write this up!