Home/Bret Cameron
Author
BCBret Cameron

Bret Cameron

2 articles by Bret Cameron.

Frontend — A Comparison Of async/await Versus then/catch — Smashing Magazine

A Comparison Of async/await Versus then/catch — Smashing Magazine

In JavaScript, there are two main ways to handle asynchronous code: then/catch (ES6) and async/await (ES7). These syntaxes give us the same underlying functionality, but they affect readability and scope in different ways. In this article, Bret Cameron will show you how one syntax lends itself to maintainable code, while the other puts us on the road to callback hell!

BCBret CameronBret Cameron·November 23, 2020Frontend