3 ms·
Introduction to asynchronous JavaScript
- bluepnume 10y agoHmm. An article in 2016 about async javascript without any references to async/await? Also, using promises to make code look prettier is kind of missing the point, and can be achieved with callbacks too. The real reasons to use promises are: 1. Error handling/bubbling 2. No chance of 'double callbacks' 3. Value-oriented code 4. Easier composition of async tasks 5. Ease of migration to async/await