I'm currently working on developing a node.js application in Visual Studio 2015, but I keep encountering an issue:
TS2304 Cannot find the name 'Promise'
In my project settings, I have ECMAScript 6 set up as the build system and ES 2015 as the module system.
I've already attempted the following:
how to use es6-promises with typescript?
How to use Typescript with native ES6 Promises
Unfortunately, none of these solutions have been successful for me. Interestingly, the second link suggests that it should work with ECMAScript version set to 6, but that hasn't resolved the issue for me.
EDIT: After more investigation, I've identified the root cause to be a mismatch between the ECMAScript Versions utilized by IntelliSense and the build system.
This became apparent when using additional ECMAScript 6 functions, triggering the following IntelliSense error:
TS1311 Async functions are only available when targeting ECMAScript 6 and higher.
So my new question is: Where can I specify the ECMAScript version that IntelliSense should utilize?