3 ms·
I think if you are so reliant on static type checking that you can’t live without it, well, there you go. But it doesn’t seem like it has to be more of a proble
by hyperhello 3y ago
I think if you are so reliant on static type checking that you can’t live without it, well, there you go. But it doesn’t seem like it has to be more of a problem than an hundred other oopses you deal with like passing parameters in the wrong order.
Most of JS’s most public issues come from thinking every programming language is
C++.
- Clamchop 3y agoFraming type checking as a crutch is a new one to me.
- hyperhello 3y agoIt’s not a crutch at all, it’s a very useful tool and central to a certain style of programming. There are other styles of programming, like prototyping and scripting, where just relying on yourself not making the mistake in the first place is better.
- NoahKAndrews 3y agoStatically typing your parameters prevents a lot of instances of passing them in in the wrong order. And if you make a habit of using a single statically typed options parameter instead of multiple parameters that have the same type, you can make passing parameters in the wrong order completely impossible in your codebase.