Answer the question
In order to leave comments, you need to log in
Promise or async/await?
What is the best use to work with asynchronous js? Before that, I used exclusively Promise, but then native async / await appeared, I don’t know which way to look.
Answer the question
In order to leave comments, you need to log in
Historically, callbacks came first, then promises, then async/await.
At the same time, promises differ radically from callbacks, and async / await can be considered as "sugar" to promises. Ideally, use async / await everywhere, where it is impossible or inconvenient - promises, and even less often callbacks.
I combine. When Promise hell is not planned, then it is quite convenient to use promises
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question