Microsoft released TypeScript 2.1 Wednesday with upgrades that reduce the friction of starting new projects, more powerful type-checking, and tools to write more expressive code.
Down-level async functions in version 2.1 let developers use async/await and target ECMAScript 3 and 5 without requiring any other tools. Users can write code around promises while not having to use callbacks. “Bringing down-level async/await to TypeScript involved rewriting our emit pipeline to use tree transforms. Keeping parity meant not just that existing emit didn’t change, but that TypeScript’s emit speed was on par as well,” said Daniel Rosenwasser, Microsoft program manager for TypeScript.