3 ms·
Callback hell was solved years ago with promises and async-await.
by paavohtl 7y ago
Callback hell was solved years ago with promises and async-await.
- z3t4 7y agoActually I prefer callbacks over promises, but it can sometimes be nice to have async/await aka. pseudo-treads / co-routines or "fibers". I belive it's much easier to learn about first class functions, then to learn the concept of Monads, and Promises was rushed into the JavaScript language, while it would have been better to wait for userland libraries to settle on a standard before carving it in stone.