What about redux thunk, it allows redux to perform async dispatches. Im not sure if this will help, but i suggested this because it seems when one of your dispatches if fired off youd like it to determine something wait for a response then finish the action.
Hey, thanks for the response. I have thought of this approach before, this is what I have tried (#2 in "What I tried", perhaps I didn't mention Redux-thunk in the post). But we need to access the state in action creators, which I believe is not advised. If accessing state from action creators is considered ok, I am glad to go with it. I am pretty sure this solution works, but I want to code as per the good guidelines.
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.
What about redux thunk, it allows redux to perform async dispatches. Im not sure if this will help, but i suggested this because it seems when one of your dispatches if fired off youd like it to determine something wait for a response then finish the action.
github.com/reduxjs/redux-thunk
let me know if this was any useful, I am also curious.
Hey, thanks for the response. I have thought of this approach before, this is what I have tried (#2 in "What I tried", perhaps I didn't mention Redux-thunk in the post). But we need to access the state in action creators, which I believe is not advised. If accessing state from action creators is considered ok, I am glad to go with it. I am pretty sure this solution works, but I want to code as per the good guidelines.