Disclaimer: This is not a serious post. It’s intended to be a little tongue-in-cheek. Before you try and start a war in the comments section for either the “JS sucks” camp or the “JS is the second coming” camp, I won’t be approving any of those comments as THIS POST ISN’T SERIOUS and I’m not speaking for either side.
I’m currently working to replace my authentication and authorization microservices in Oystr. As a result, a single request from a browser requires multiple requests to the security database meaning there are a lot of callbacks. At the time I built it, I used promises as that was the thing to do. What has become apparent in my revisit is that promises make your code extremely difficult to follow. With callbacks, although you have deeply nested structures, your code was somewhat linear. With promises, your callback logic is “deferred” and as a result you find that the code just jumps everywhere.
Async/await should hopefully help resolve some of the problems with this but seeing Chrome only just started supporting it this month (December 2016), you’re probably going to continue to see the horror of promises for some time to come. Promises were meant to be a panacea for callbacks, but on reflection, they’re really just a “deference” of the problem to another part of your code-base.