Main pain points with TS have become more obvious as the team grew and the codebase resulted in a multitude of different models representing the same thing.
- Prisma model representing the things (plural because Prisma generates a ton of variants for the different read/write scenarios) going in/out of the DB
- Zod models for OpenAPI generation
- Zod models for deserialization where we have `jsonb`
- DTO models at the boundary
- Additional front-end payload models that wrap the DTOs
A developer building a simple API endpoint do to a read will often up writing a handful of models for the same entity to move it back and forth...A lot of this work simply ends up being related to the loss of runtime types requiring a lot more modeling work creating a spaghetti of Zod and types.
Lots of papercuts in day-to-day and increasingly difficult to get otherwise competent engineers onboarded.
At least I'm not under the impression that this is a Silver Bullet. Will C# make it better? We'll see!