Skip to content

Comment on Refusing TypeScript is a signal that you don't care about code quality

Comments

Developers who see a static type checker as making their work more "difficult" have generally not learned to read code very well.

If you are comfortable reading code critically, a major part of what you are doing is inferring a type for each variable/function/class, whether you know that or not. You mentally infer types like "positive integer".

Developers who are not mentally inferring types instead reason about code purely at the value level. If you read code purely by walking through value transitions, it seems natural enough to think that automated tests (assertions about values) are sufficient.

The jump from value-only reasoning to type-reasoning is very much like the jump from algorithmic to proof-based mathematics.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.