Handling Nested Errors with Type-Safe API Interactions
What's the best way to handle nested errors? My particular use case is (type-safely) interacting with a remote API that only sometimes responds with errors in a specific schema.
Here
Here
RecordNotFoundSchema is a schema mocking the error response from the API. I believe catchAll might be a way around but I'm not sure if it's the most idiomatic method.