Summary

TypeScript is a superset of JavaScript. This means you can write plain JavaScript in .ts files. The TypeScript compiler will peel all the extra TypeScript code and produce code that is plain, readable, and almost identical to the source code. The Angular 2 team uses TypeScript for developing the Angular platform (the source code is written with TypeScript, but a compiled JavaScript version is also available). As developers, we can choose whatever we want to use; TypeScript, JavaScript 2015 (ES6), or JavaScript 1.5.

If you choose to use TypeScript, it's highly recommended to visit http://www.typescriptlang.org/ and learn more about the language's capabilities that go beyond the scope of this book.

Get Angular 2 Components now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.