Answer the question
In order to leave comments, you need to log in
Why Redux Saga if there is Redux Thunk?
Why Redux Saga if there is Redux Thunk A bunch
of methods, huge documentation who needs it?
Answer the question
In order to leave comments, you need to log in
Redux-saga is an alternative approach to organizing side effects. Instead of dispatching functions that are processed by redux-thunk, you create a saga that collects all the processing logic inside itself. Unlike thunks, which are executed when you dispatch them, sagas are launched at application startup and “run in the background” as it were. Sagas listen to all the actions that the store dispatches and decide what to do with them.
And sagas in redux have two advantages over thunks:
- They allow you to organize complex sequences of side effects
- And they are very easy to test
If you doubt whether you need this dependency in the project, then it is not needed.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question