4 ms·
Using JS instead of TypeScript is very short-sighted and they will regret it, eventually. Sounds like they got frustrated and gave up. Their arguments remind m
by WClayFerguson 6y ago
Using JS instead of TypeScript is very short-sighted and they will regret it, eventually. Sounds like they got frustrated and gave up.
Their arguments remind me of someone saying they want to use Assembly Language instead of C++, because assemblers are faster than compilers, or to not have to worry about memory heap issues, etc.
All you're doing by switching from TS to JS, is trading one set of minor problems (which are solvable) to a more vast set of even larger problems that are NOT solvable.
- inimino 6y agoSpoken like someone who's never solved problems with medium-to-large scale JS projects... criticising people who have.
- holler 6y agoThat is one key thing I see a disconnect with. I definitely can see the value in having static types in a long-lived/large js project, but at the same time 1) how long does the average js project really stay relevant, 2) people have got by just fine w/o it so far. I’m kind of mixed on it, but for my new web app I’m working on I decided to use vanilla js because it feels much more efficient.
- WClayFerguson 6y agoAnd if you converted your code to TypeScript you'd immediately find the 100 or 1000 bugs you have that you're just unaware of until they bite. People who have done such a conversion before know this, and unanimously will agree. Those who have't are blissfully ignorant.
- WClayFerguson 6y agoHere's a pretty sizable project I wrote in pure TypeScript: https://github.com/Clay-Ferguson/quantizr https://github.com/Clay-Ferguson/quantizr I have 5 years experience in TS and 20 in JS. Trust me, if you don't yet understand the value of type-safety, it's only because you haven't lived long enough yet.
- inimino 6y agoI do understand the value, thanks mostly to Haskell. I also know that (language- or tool-enforced) type safety and type discipline are separable concerns. I also understand when the former gets in the way, thanks to JS, TS, Rust, Lisp, and projects large and small, slow and then fast, fast and then slow, slow and then slow, and fast and then fast.
- WClayFerguson 6y agoEvery developer, regardless of skill level, makes mistakes and typos. The beauty of type-safety in TypeScript is that the compiler catches it instantly, in a way that is simply humanly impossible. If I misspell something, or provide the wrong argument type to a method, or have args in wrong order, etc, it's caught instantly. With JS you can have a typo that causes user malfunctions for YEARS before being found by a developer and fixed. Any developer who's done many years of both TS and JS would never in a million years consider going back to JS. Absolutely out of the question.
- inimino 6y ago> Any developer who's done many years of both TS and JS would never in a million years consider going back to JS. Except, apparently, for the topic of this article. > If I misspell something, or provide the wrong argument type to a method, or have args in wrong order, etc, it's caught instantly. Yes, I've heard the pitch before. I've even given it more than a few times. Of course, if both of your arguments happen to be 64-bit floats, then the type system won't help you much if you get them in the wrong order. However, when you want to change that function to take a closure instead of a number, the type system can be invisible or it can fight you. Some of us love the structure that a type system can provide. Some of us, like the one who started this website we're on now, also appreciate the power of languages that get out of your way and let you make your own brilliant mistakes. And some of us can appreciate the beauty of different language designs and approaches, and try to rise above dogma. Which, if you've been in this line of work for 20+ years, should be you.
- 6y ago