Async not working Atom TypeScript

Viewed 218

I am learning TypeScript using Atom IDE.

Question is, when I try the below code

async function fn1() {
    throw new Error("Not implemented yet");
}

I get an error

An async function or method in ES5/ES3 requires the 'Promise' constructor.

However if I paste the code in https://www.typescriptlang.org/play/index.html

it compiles correctly . Moreover I am not getting any suggestions when I use Promise in Atom.

2 Answers
Related