Half my dev time fighting TS types
Are we just using ts wrong? ts is newer to me - I was in laravel and dotnet before with very structured dto's and almost never had to touch types unless there was db changes.
I get that functional programming is meant for small single use functions that define only the type of the object that it needs, but in my opinion, thats lead to a mess of types across the codebase and I miss the structured dto's being defined in one place and thats the type that gets passed everywhere.
I'm not naive so I know I'm not the first dev to encounter these issues w ts so could someone tell me if we're just not using it correctly? I know we could define dto's in ts I'm just not sure if thats defeating the functional purpose. Does anyone else feel like they are spending way too much time wrestling types?