JavaScript is well-known for its syntactic horrors. What happens when you "+" an object to an array? What happens if you do it the other way around? How do you encapsulate data inside a JavaScript class and how do you combine classes into modules? How do you inherit from a class? TypeScript is a new open-source language designed by Microsoft's Anders Hejlsberg (the father of C) which compiles to clean, readable JavaScript. TypeScript offers a variety of great features including constructor syntax, inheritance, interfaces, strong type checking for function parameters, and modules. In this session we will review some idiomatic TypeScript code and understand how it is translated to JavaScript. |