Full Stack Error Handling Type Safety (Either VS Errors) #1176
danielyogel
started this conversation in
General
Replies: 1 comment 5 replies
-
I've gone back-and-forth on this over the last few years. At the moment I prefer treating errors as exceptions. You can return an Furthermore - you can do explicit error formatting in tRPC - not sure if you've played with |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Was wondering, if anyone uses an Either type (together with always 200 status code) - instead of throwing - in order to achieve error handling type safety in the client?
Any reason why this may be a bad idea?
Beta Was this translation helpful? Give feedback.
All reactions