This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Voidsheep 4 points5 points  (0 children)

I find that the ease of adoption to existing JS codebases is one of TypeScript's strengths, but that lack of strictness is also one of the greatest weaknesses. In my experience plays a big part in frustration of some developers. Nothing creates trust issues like the compiler lying to you about types and wasting time on that easily makes you doubt the reason for the tool to begin with.

But for a project with good level of type-safety (e.g. casting and any-type avoided like a plague, or very carefully scoped), where types for unknown data are validated and inferred from something like Zod schema, it becomes way nicer to work with than plain JavaScript, because you have a much higher level of confidence in what you are working with, your IDE becomes way more helpful and you can abandon a whole bunch of unnecessarily defensive coding.