Opinion #TypeScript#Web Dev 6 min read

Why TypeScript is not enough

And what we actually need from a typed JavaScript

Published May 13, 2025 Updated May 27, 2026

TypeScript's real value

TypeScript catches a class of bugs at the editor level. That is genuinely useful. For large codebases, the productivity gain is real.

The gaps

  • Soundness is opt-out by default: any permeates third-party types, as casts spread quietly, and type guards are unchecked at runtime
  • No runtime types: the types disappear at compile time. JSON.parse returns any. Production bugs happen in the gap between what the type says and what the wire sends
  • Structural typing surprises: excess property checks only at assignment, not in all positions

What would actually help

Zod and similar libraries address the runtime gap, but it is awkward to maintain two schemas. Effect-TS goes further with typed errors. Neither is mainstream.

The honest take

TypeScript is a massive improvement over plain JavaScript. It is not a substitute for a well-typed language. Know what you are getting.

Share this article
X LinkedIn
Weekly digest

One email a week.
The five things that mattered.

Friday mornings. No hype. Unsubscribe anytime.

No spam.