First things first…
2. Typescript takes what is considered a “loosely-typed language” and shores. it up very nicely. What does this mean? It means you have to define certain things that you don’t in typically JS. JS is happy to do some conversions under the hood for you, in order to make for a more flexible experience. Typescript, however, has no interest in those aspirations. If you’re passing in props, you’d better assign it a property type. We call this “static typing”. What is it? A string, an integer, a boolean? These things need to be defined, as if you drop an integer into a field that requires a string, its going to be trouble.
3. Typescript is going to give you a more robust experience in your IDE as well. As a user of VSCode, I’ve found that handling errors can be a bit difficult, as oftentimes you are not told explicitly the error that you’re dealing with, merely a location. Typescript is good at bridging that gap by offering more detailing in your errors. The language reads a bit more plainly and will guide you on your path to bug free coding.
4. If you’re familiar with Babel, you know that Babel can be a big help in converting JS code into code thats usable across many different iterations of its platform. Typescript has that compiler built in, so code you write in Typescript will automagically become available in older browsers.
This was a quick 1–2 on Typescript! I feel that at the end of the day the biggest thing to note is Typescript is another stopgap measure to make sure your code runs cleanly. If it forces specificity that will reduce problems in the future. It also gives you more information about where your errors lie, which can save time in debugging, and combing through code. Easy breezy!