DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

Jatin pal
Jatin pal

Posted on

Javascript vs Typescript

Hello friends I want to find out what the difference is with javaScript our typescript which is the batter programming language out of these two and they can be used in web development

Top comments (7)

Collapse
aftertale profile image
Aftertale

Typescript is a superset of JavaScript that adds strict types. The browser can only execute JavaScript, so in web development, the typescript will be β€œcompiled” into JS for execution in the browser. The primary advantages to TS are compile-time type checking being advantageous for catching bugs earlier, better intellisense in your ide, and overall better determinism in your application. You will need to understand JavaScript in order to best utilize typescript, so you would be best served learning both!

Collapse
sam_piggott profile image
Sam Piggott • Edited on

Hey Jatin!

Rather than being a separate language entirely, TypeScript adds more features and functionality to JavaScript.

I personally would suggest you start to learn JavaScript first, then upgrade to TypeScript once you've got a grasp on the basics of JavaScript. TypeScript's super powerful, but it's also not for everybody - it's a matter of personal preference.

I posted an article last week about learning TypeScript as a JavaScript developer here - it might be useful.

Good luck!

Collapse
creativecreate8 profile image
Jatin pal Author

I blogged about your typescript and JavaScript. That is a very useful blog.

Collapse
luscala profile image
Luca Scala

Google will answer that question easily. There’s a lot to read about it!

Collapse
creativecreate8 profile image
Jatin pal Author

Thanks

Collapse
rxliuli profile image
rxliuli

Personally, since last year, I have basically been using ts. Although I encountered many problems in the middle, I still believe that ts is the future of js

πŸ‘€ Just want to lurk?

Β 
That's fine, you can still create an account and turn on features like 🌚 dark mode.