Show HN: Tsfix – Fixing the ESM compatibility gap TypeScript won't solve
github.comTSFIX was born out of my own frustration with the current ESM situation in TypeScript. And I'm sharing it hoping it might save others the time and headaches I went through.
Basically it solves three fundamental TypeScript frustrations:
1. TypeScript's compiler (`tsc`) can't produce valid ESM output
2. Using bundlers to fix ESM output creates misalignment with type definitions
3. We should be able to use `.ts` extensions in our source files since that's what they actually are!
It's a simple post-build tool that:
- Transforms `tsc` output into valid ESM by adding proper extensions
- Ensures your type definitions match your actual code structure
After 8+ years of open TypeScript issues, I got tired of waiting for a proper solution.
GitHub: https://github.com/2BAD/tsfix
P.S. Did you know none of the top 100 TypeScript projects on GitHub use `tsc` for production builds?
No comments yet.