JS Promise

Creator
Creator
Seonglae ChoSeonglae Cho
Created
Created
2020 Feb 21 4:22
Editor
Edited
Edited
2025 Oct 6 9:32
Refs
Refs
An object containing a state [[PromiseStatus]] and a value [[PromiseValue]]
Enables writing intuitive asynchronous code when used with async/await. It was developed to address the poor readability of deeply nested callbacks. With callbacks, asynchronous operations must be nested, making exception handling difficult and reducing code readability.
JS Promise.all()
doesn't provide information about which promises failed, so we need to retry the entire list when it fails. However,
JS Promise.allSettled()
shows which promises succeeded or failed, allowing us to retry only the specific failed requests.
JS Promise Notion
 
 
JS Promise Usages
 
 
 
 
⭐️🎀 JavaScript Visualized: Promises & Async/Await
If you're here in 2024 (or later), here's an updated video: Ever had to deal with JS code...
⭐️🎀 JavaScript Visualized: Promises & Async/Await
Promises
This article was originally written as an answer on Stack Overflow. The hope is that by seeing how you would go about implementing Promise in JavaScript, you may gain a better understanding of how promises behave.
Implement a Simple Promise in Javascript
In front-end engineering interviews and daily front-end development, we encounter Promises all the time. In these interviews, I have been…
Implement a Simple Promise in Javascript
 
 

Recommendations