-
Notifications
You must be signed in to change notification settings - Fork 122
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: Consistent Backend Error Responses should have a way to parse them? #250
Comments
After some tests: My REST endpoint return 200 with the response (either object or array) for the happy path. When there is something wrong with the request they return 400 and an object with a property called errors When 400 is met (example: user trying to register with an unsafe password) apollo tries to save the response into the cache expecting an object like this
Since the actual response is My solution for now is to pass |
If you want to add a feature to handle error responses somehow I'd be happy to discuss it further. |
ApolloClient has changed significantly in 3.x, and apollo-link-rest's version v0.8.0 is the current version of the project that's compatible with that. If you can replicate this in v0.8.0 @huylocit14054 then we can investigate this further. |
I am integrating apollo-link-rest in a react native app but if I do not disable the cache I always get this error:
Here my mutation
And also how I create link and client
I have tried to use cross-fetch but the outcome is the same, the only way is to disable the cache.
The text was updated successfully, but these errors were encountered: