/dev tips

(181) Expand all DOM nodes Quickly access the DOM Tree from JavaScript (183)

VS Code: Automatically convert your Promise chains into async/await

8th November 2018
Automatically convert your Promise chains into async/await

Visual Studio Code can now convert your long chains of Promise.then()'s into async/await!

In theory, this should also work with Sublime Text when using the TypeScript plugin.

Note: You do not need to write TypeScript code to use this feature, it works with vanilla JavaScript.

Confirmed working with TypeScript 3.1.1.

You can also check out this Twitter thread which includes some extra information twitter.com/umaar/status/1045655069478334464

Sign up to receive a developer tip, in the form of a gif, in your inbox each week.