Search code examples
reactjsredux-saga

Should we use redux saga for post requests?


Should we use the redax saga when we make a post request to the server but expect to receive some data after that and dispatch it to the store?

For example, I send a post request on page reload if the user is logged in to check if his token is valid, and if so, update the state in the store


Solution

  • Redux Saga is primarily used for side-effects management. So to answer your question - yes.