Pros/cons of using redux-saga with ES6 generators vs redux-thunk with ES2017 async/await

There is a lot of talk about the latest kid in redux town right now, redux-saga/redux-saga. It uses generator functions for listening to/dispatching actions. Before I wrap my head around it, I would like to know the pros/cons of using redux-saga instead of the approach below where I’m using redux-thunk with async/await. A component might … Read more

Why do we need middleware for async flow in Redux?

According to the docs, “Without middleware, Redux store only supports synchronous data flow”. I don’t understand why this is the case. Why can’t the container component call the async API, and then dispatch the actions? For example, imagine a simple UI: a field and a button. When user pushes the button, the field gets populated … Read more