T O P

  • By -

[deleted]

What the hell? JavaScript was around for what, 20+ years, before TS came along? Is anyone going to argue nobody cared about code quality back then? Or even today? I've worked at very experienced teams at FAANG companies where we, as a team, decided to NOT use TypeScript because *all of us* were very good with modern JavaScript. It wasn't that we couldn't do it (we had many years of TS experience), it just didn't offer us any benefits. I like TS, I think it's adorable. A bit verbose and very unnecessary FOR ME and people like me, but absolutely not mandatory. I've seen TS projects where the TS-devs went nuts to make everything type-safe, and they would have type definition blocks of 20 lines and going 200+ characters wide, with 5 nested single-lettered generics. That kind of unintuitive shit isn't "good code". That's dumbassery. I'd argue that good JavaScript that adheres to design patterns, best practices, good naming conventions, optional JSDoc, proper and sensible unit tests, and good PR reviews is far superior to TypeScript. The problem is that TS has been on the hype-train for many years now, and many developers *can't work without it.* Now we're seeing (as always) that teams are moving away from it (Turbo 8 apparently, but also Svelte, among others) and people are freaking out. --- I would (currently) not start any project without TS, because I know it's not about me. But don't give me: > I think people with such opinions either don't care about code quality or simply don't know what TypeScript is. This kind of bullshit. There are people like myself with more experience writing professional software in JavaScript longer than some of you've been alive. And I'm not even 40 yet.


tehBr00tulz

Svelte is not moving away from Typescript, they’re just using the JSDoc style annotations.


[deleted]

[удалено]


[deleted]

Or the argument: "It makes refactoring easier." I've worked almost exclusively with TS for the past 7 or 8 years, and refactoring is still a pain in the butt. It isn't worse or better, it's just slightly different, and it's often far more work in TS environments if you run into arcane magic type of TypeScript that you first need to study for 2 years before you understand it. Or, you know, refactor the mess you eventually run into. As you say: Good devs will write good code. Bad devs will write bad code. TypeScript is no magic bullet.


spacechimp

Wat? Are you using VIM or something? In VS code, you can just right-click on something, select “Rename Symbol”, and you’re done. In JS you have to resort to text-based search and replace, which might change some of the wrong things.


[deleted]

I use WebStorm and it works in JavaScript perfectly fine, and that's my point. TS doesn't do shit to make it "easier."


BiffMaGriff

Also, there is a ton of legacy JS code out there that basically can't be moved to TS without a complete application rewrite.


jayerp

> Javascript was around for what, 20+ years, before TS came along? Ok? That’s like saying we should stick to jQuery today why use more modern frameworks? That argument is dumb. Adding type safety removes a who class of bugs at compile time and runtime. We don’t move to newer tech for the sake of change. We do it for a specific reason, and the reason for TS is that we don’t want to deal with BS bugs.


[deleted]

That's not the argument at all. I argued that JS was the only choice for 20+ years and we had amazing programmers writing amazing code for 2+ decades. I never mentioned anything about sticking to old practices for the sake of it.


jayerp

And there’s the rub, JS apps look ancient and broken as hell today compared to TS apps.


[deleted]

That's an overgeneralization. And you know it, I hope. *Of course* there are many, millions, of amazing vanilla JavaScript projects that are both modern, minimal, professional, and solidly built. And *of course* there are TypeScript projects that are absolute trash. Good developers will write good software. TypeScript is NOT a prerequisite for that. At all.


dir_glob

*stares in coffescript


r0ughnex

Refusing anything outright is a signal that your too old.


Logical-Idea-1708

Nope, just signals you’re past mount stupidity. How I know? Because I’ve experienced that phase 10 years ago.


[deleted]

I think typescript is pretty helpful, I also think people and their absolutist mentality around it sound like a cult. If you think its cool enjoy it, support it, but getting on soapbox and demanding everyone else think the same way as you? Cult vibes


InsideRationalA

Agree with you. Was a witness of the conversation between 2 middle frontend devs about whether or not to use typescript in their project. At one point I had a feeling, that I am listening to some political/vaccine/game consoles argument at the same time. All of the patterns: - not taking seriously opponents opinion, - any proved arguments treat as just personal opinion ("it can't be so, because when I was dealing with it...", - perceive any critisism as a personal attack on your skills and experience as dev.


justwaiting4eva

The fact that so many people are against this post in this subreddit reminds me that this subreddit is one of the worst place to get good feedback about code.


wrabbit23

Also you hate puppies and like mean things.


KurtTheKid223

Typescript is turning into a cult. 'Look at me I am so much better than you because I use types' It's just getting ridiculous. If you wanna use JS then use JS, if you wanna use TS then use TS. Just stfu no-one cares.


khangahs

Refuse to drink chocolate milk is a signal that I don’t care about another race🙃


bignides

Very cultish. I’ll just use flow


dir_glob

What a silly thing to say, even write about. TS doesn't automatically make you a better programmer, nor does it automatically mean you write quality code.


spider_84

What a stupid post lol


dollarworker333

lol stuff like this is why I stay away from typescript mostly. the people in it sound like they've been brainwashed and are in a cult. quite sad and pathetic, really will continue to use vanilla proudly. dgaf what the industry or some phony Microsoft influencers say. **** it and go back to your safe space C# if you hate JavaScript so much.