Our great sponsors
-
SurveyJS
Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.
-
ember-concurrency
ember-concurrency is an Ember Addon that enables you to write concise, worry-free, cancelable, restartable, asynchronous tasks.
redux-saga makes use of them in really nice way. https://redux-saga.js.org/ That’s where I’ve used them the most.
If you look at Redux-Saga as others have pointed out, that library is essentially an abstraction over a concurrency primitive known as Communicating Sequential Processes (CSP), which was invented by Tony Hoare (the same person who invented null). This is an alternative to using something like RxJS or the Actor model. If you want to see a more traditional implementation of the CSP idea in JS, have a look at js-csp. And, if you're wondering if they resemble channels in Go, then you are right - it's the exact same idea.
I wrote a super-lightweight alternative to Redux-Saga called Conclure (https://github.com/dmaevsky/conclure) which quite literally allows for a drop-in replacement of async/await -> function*/yield. The advantages you get on the other hand are flow cancellation, testability, and synchronous completion whenever possible. These turned out so consequential in so many cases that in my company we literally reject PRs if they contain the word "async" :)