Understanding TypeScript's benefits and pitfalls - LogRocket Blog
Briefly

JavaScript's dynamic typing allows for flexibility, but it adds extra complexity and risk.If someone passes a Number to a function that expects a Date, it's likely that the function will throw an exception unless the function adds some extra code to ensure that the argument is actually a Date.
...
Type checking is the primary advantage of TypeScript.By adding static typing to the language, we can catch many of these problems at build time.
...
It's easy to be lulled into a false sense of security with TypeScript.Even if your entire project is written in TypeScript, has rigid type definitions, and has the strictest type checking turned on, you are still not safe.
Read at LogRocket Blog
[
add
]
[
|
|
]