So, what’s TypeScript?
When Niels Nijs asked me about TypeScript, I noticed it was in fact a very good example of the Forward Polyfill philosophy. It was therefore interesting to speak a bit about it on my blog.
This means that the degree of coupling in your code quickly becomes unmanageable and this will hurt your maintainability on the long run.
It’s very possible that small mistakes will stay unnoticed until runtime because they’re difficult to spot, which can make your web apps less reliable than you would like.
What TypeScript adds
However, TypeScript allows you to give an “indicative” type on variables, function parameters and return values (hence the TypeScript name). This will help the Visual Studio IDE to provide you the good refactoring experience (intellisense, go to definition, rename, find all references, …) you already know and love when working with C# or VB.
This includes C#-like lambda expressions, classes and namespaces (modules).
Classes and modules give you the opportunity to define “public” or “private” constructs that will or not show up in the intellisense at relevant places.
This helps you to keep your code reliable and coherent.
Where’s TypeScript going to
It’s very likely that your TypeScript code will become (with very few changes) a valid ECMAScript 6 code when browsers will start to support it.
- The official website of TypeScript
- Microsoft TypeScript : A quick introduction (for CSharpers)