So, what is so appealing about TypeScript? I did a thorough research, asked a few of my fellow developers to tell me why this particular language stood out to them as well and they gave me some great responses.
Building very large applications is now possible
Developers are sometimes required to work dedicatedly on an application – from the prototype development to actual deployment and then maintenance. However, most of the times, this is not the case. Especially when developing large-scale applications. We, for example, have a large team of developers, test engineers and whatnot where each person is handed a different task. They might be codependent, yes, but there is still a large team handling a single project.
It might not be a problem under different circumstances but without proper type information in place, the situation gets messier every time there is a need to replace, rename or refactor a code. Imagine half a dozen people omitting and replacing codes manually (which is quite error-prone, honestly). TypeScript saves the day for the development teams, both literally and figuratively.
The language service knows where there is a need for a renaming and instantly does the replacement work for you; saving you both time and effort of searching, identifying and replacing the bloop. It is extremely beneficial when you are working on an application that is constantly growing in size and scale.
Interfaces, abstract classes, algebraic data types, static checking, code refactoring, auto-completion, async functions, decorators, just name them and you have them with TypeScript. Plus, the object-oriented programming, optional static typing disciplines, modern IDE capabilities, million-line applications, and TypeScript are active on any web browser/host or OS; A luxury that was not possible otherwise. When working with interfaces, developers can leave their worries over details aside and simply dive into the world of TypeScript.
Ease of familiarity
Perhaps the most popular reason for the easy adoption of this transpiled language; developers don’t need to learn anything new as it carries same syntax and semantics as other C#, Java, C++ and other structured languages. You can easily build web and native mobile applications with the same languages. It is built especially for the programmers who are used to structured programming.
Think of it as reheating your last night’s meal. You aren’t cooking anything new, the ingredients are all the same; you are just popping it in the microwave (hello technology!) and waiting for it to heat. It doesn’t matter how your meal was actually prepared. You just need to know how to use a microwave!
Clean, simple code without added complexities
Auto update is easier than ever
TypeScript brings newer ECMAScript revisions way before it is available on browsers. For example, you can benefit from the updated version before it is officially on the market, even without actually downloading it. Imagine the number of robust components you could build with latest features without waiting for the newer version.
Supports most of the popular editors
Working with a typed platform that doesn’t support editors (at least the popular ones) can be a painful experience for developers. Imagine how helpless we would have been if Google docs didn’t offer editing and instant sharing features. It’s the same for the developers who ‘document’ their codes and need a series of editors to work proficiently. Thankfully, TypeScript supports the MS Visual Studio family, WebStorm, Eclipse, Atom, Sublime Text, Emacs, Vim and more, making our lives easier.
The type system is optional
This is the absolute deal. Type system, when turned on all the time, is a big headache. The running error-detection courtesy type system overwhelms you, giving you little or no breathing space to actually get the bugs squashed. With type system being optional, you get the freedom to define interfaces between software components and handle bugs better.
TypeScript in action: Popular examples
As explained earlier, there are a number of frameworks that utilize TypeScript as their typed codebase. However, we have a few extremely popular applications and platforms to add to the list.
3. Asana: Asana, a popular publishing and task management platform, went for TypeScript as it allowed them to manage large codebase without any added code complexities. Another reason was that now the application was growing in size which called for constant refactoring– TypeScript’s specialty.
What lies ahead for TypeScript?
Web development is advancing at a lightning speed. New technologies are making debut, earlier ones are seeing revisions over revisions over the period of a few months. TypeScript is only 5 years old, yet it has seen some amazing days (or years). This popularity is nowhere towards the end.
TypeScript 2.8 was released only a couple of weeks ago, offering significant improvements and promising features.