-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
default errorPolicy : "all" #11682
Comments
Hey @schoenbergeringo 👋 Just an FYI, our community forums or Discord server are a great place for these types of questions 🙂. Unfortunately I haven't been around long enough to know the original motivation behind the decision to make
Yes! You can set new ApolloClient({
defaultOptions: {
watchQuery: {
errorPolicy: 'all'
}
}
}); Using useQuery(query, {
// will be used instead of the default 'all'
errorPolicy: 'none'
}); |
thank you @jerelmiller that helped |
Do you have any feedback for the maintainers? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo Client usage and allow us to serve you better. |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Hello everyone,
I just wanted to know if there is a specific reason not to have errorPolicy: "all" as default. With the current default errorPolicy : "none" mutations are not updating the UI to the latest state of the backend, if one of the fieldresolvers return errors. So I am normally adding to all the mutations errorPolicy: "all" to avoid this issue. Is this a mistake by me ? Is there a central place to set this errorPolicy to what i want ?
Thanks, would be nice if someone could explain this to me
The text was updated successfully, but these errors were encountered: