How to Implement Promise.race with Conditional Short Circuit in Node.js & TypeScript

Published: 31 August 2023
on channel: Rowadz
239
10

Buy me a coffee if this is useful 😀
https://www.buymeacoffee.com/rowadz

race promises until a condition applies in Node.js & TypeScript 🚀⚡

Learn how to supercharge your asynchronous programming in this concise video

code:
https://gist.github.com/Rowadz/87cbb4...

Promises techniques 🎊:

   • Promises techniques 🎊  

HTTP requests orchestration techniques 🪄:

   • HTTP requests orchestration techniques 🪄  



00:00 Explaining the idea
02:25 Start writing the code
03:16 Creating a map to hold the promises's statuses
07:14 Calling Promise.race
07:58 Continuing the race
08:43 Testing
09:28 Testing with a delay
10:00 Testing with an error
11:02 Testing with a rejected promise


Watch video How to Implement Promise.race with Conditional Short Circuit in Node.js & TypeScript online without registration, duration hours minute second in high quality. This video was added by user Rowadz 31 August 2023, don't forget to share it with your friends and acquaintances, it has been viewed on our site 239 once and liked it 10 people.