Async/Await in Asynchronous Javascript

To handle asynchronous Javascript, callbacks were first used but it had major cons like callback hell. Then came about promises to try to improve things. However, .then chains can also get nested and confusing.
So now, we have async/await, which was introduced in NodeJS 7.6 and is currently supported in all modern browsers.

--

--

--

Senior Software Developer at @thoughtworks | Marathon Runner | Ex-Pharmacist Writing on Coding, Technology and Running

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Turn Any* JavaScript Library into a React Native Component

How use angular/google-maps first look

VS Code Live Share Support, and more…

A front-end development review of 2017: JavaScript, Firefox, and more

WeakMaps in Javascript

Top string problems for interview

How to dispatch multiple async actions in one function in Redux?

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Sherlynn Tan

Sherlynn Tan

Senior Software Developer at @thoughtworks | Marathon Runner | Ex-Pharmacist Writing on Coding, Technology and Running

More from Medium

Asynchronous Programming in Javascript

Image representation of Asynchronous Programming in Javascript By Yasir Gaji

How TypeScript works with JavaScript null and undefined values

JavaScript , Git , NoSQL

More About JavaScript, Version Controlling, NoSQL