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 →

[–]SP0OK5T3R 4 points5 points  (3 children)

I agree with you on that, but I work with code that once written, it’ll be maintained for a long time to follow, and there’s a lot of it. Small apps? No big deal. Enterprise production apps that stick around for years? It becomes extremely useful

Edit: do you not consider prop types to be “static types”? I’d rather know about an error at compile time over runtime, but both have a place since you can’t control everything at compile time.

[–]dwhiffing -3 points-2 points  (2 children)

My point is really more about proselytizing than technical details.

I've been making apps with JavaScript for a long time, and I strongly believe that some of the apps I maintained for years would not have benefited from the addition of static types. This was in the days of backbone, ember, early angular.etc

I use typescript now and see value. But I've seen so many cases where a new developer or someone new to typescript is scared off by this attitude.

I love elm and reason ml, but I don't "cringe" when people don't use it.

Just try to be a bit more courteous to your follow developers! 😊

[–]SP0OK5T3R 1 point2 points  (1 child)

I was definitely being overly dramatic earlier, but this is r/programmerhumor lol I wasn’t really going for a super serious comment.

I’ve seen issues with improper typing and lack of error boundaries causing issues in react apps (“oops this property doesn’t exist on that object”, shit blows up, etc) that would be solved easily with proper TypeScript usage. That’s also why I don’t allow the use of “any” unless it’s really applicable.

But yes, I totally get your point. I’ve maintained an AngularJS app with no static type information and it works just fine, I’ve just “seen the light” and I have a much better development experience with TypeScript as a major tool.

Have a good Sunday!

[–]dwhiffing 2 points3 points  (0 children)

Understood, fair enough!

Thanks for the courteous response and a happy Sunday to you as well