You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Error Link takes a function that is called in the event of an error. This function is called with an object containing the following keys:
operation: The Operation that errored
response: The response from the server
graphQLErrors: An array of errors from the GraphQL endpoint
networkError: any error during the link execution or server response
So does it mean that onError function has lack of output or these protocolErrors and clientErrors in ApolloError type supposed to be catched other way?
Still I couldn't redproduce any of these error types on the project and don't understand in what case scenarios they are used
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi all!
Recently I was dealing with errors handling and found out that common
ApolloError
type in libBUT I also log all errors in angular provider using
onError
function which according to https://the-guild.dev/graphql/apollo-angular/docs/data/error-handling returns only these types of errors belowSo does it mean that
onError
function has lack of output or theseprotocolErrors
andclientErrors
in ApolloError type supposed to be catched other way?Still I couldn't redproduce any of these error types on the project and don't understand in what case scenarios they are used
Beta Was this translation helpful? Give feedback.
All reactions