Introduction:

When I started putting this article together, the first thing on my mind was getting a picture that is more than a thousand words. Thank goodness I found this.

My goal of this article is to help you understand what TypeScript is, why you should care, and how to get started. The picture above in essence capture what the TypeScript Engine is doing for you behind the scene, maybe we can put it like the mother hen looking out for the chicks. But online the mother hen we have to explicitly enable TypeScript to do that. That is why is more like setting up a watch system in our JavaScript code that looks out for our safety in development.

What TypeScript does?

It helps us catch errors during development, in JavaScript, you mostly have to run your code and cross your finger that the browser console doesn’t blow up. It’s important to know that TypeScript only runs in development.

Using typed annotations it analyzed our code for errors before we even run it, this provides great development experience. Before we move on to how to install and get started with TypeScript, its important to know that TypeScript doesn’t provide any kind of performance optimization for your code in production; It’s actually compiled to JavaScript so the browser or NodeJS runtime doesn’t even know TypeScript exist. Its purpose is to speed up your development provides auto-completion and catch errors early. Like the

#typescript #nodejs #code #web-development #javascript

Getting started with TypeScript for the uninitiated
1.90 GEEK