News for hackers. Stuff that matters.
Re:Redux – Not Dead Yet (2018) by acemarke on Thursday April 09, 2020 @11:33AM (#22823521)
Note that the new `createAsyncThunk` API in Redux Toolkit handles generating and dispatching the promise lifecycle actions for you [0]. Also, while sagas are a great power tool, most Redux apps don't need them [1].

[0] https://redux-toolkit.js.org/api/createAsyncThunk

[1] https://blog.isquaredsoftware.com/2020/02/blogged-answers-wh...

Re:Redux – Not Dead Yet (2018) by mikewhy on Thursday April 09, 2020 @01:22PM (#22824903)
Awesome! It's great to finally have some links to share.

The company I'm currently working with is the first time I've used sagas / observables / "anything async is through side effects". I've constantly been saying "this is madness, this giant block of code, all these concepts, all this room for things to go wrong, just to do a `fetch`?". It's also the first time in a few years of using redux I've had to deal with race conditions.

Edit: Oh, and you can even `await dispatch`! All the things I've been doing in Redux for years and told I shouldn't, now being officially endorsed.