Thursday, June 11, 2015

TypeScript–Set the version of the generated JavaScript

TypeScript is a typed superset of JavaScript that compiles to plain JavaScript. What most people don’t realize is that you can control the JavaScript version that is generated by the TypeScript compiler. By default it will generate EcmaScript 5 compliant JavaScript, but you can change this if you need/want.

To do this, right-click on your project and choose Properties. Go to the TypeScript Build tab. There is a drop down where you can choose the ECMAScript version.

image

No comments: