Error that provides either a
During a GraphQL request, either the request can fail entirely, causing a network error, or the GraphQL execution or fields can fail, which will cause an ExecutionResult to contain an array of GraphQL errors.
CombinedError abstracts and normalizes both failure cases. When error
is set to this error, the
CombinedError abstracts all errors, making it easier to handle only
a subset of error cases.
https://urql.dev/goto/docs/basics/errors for more information on handling
GraphQL errors and the
A list of GraphQL errors rehydrated from a ExecutionResult.
If an ExecutionResult received from the API contains a list of errors,
CombinedError will rehydrate them, normalize them to
GraphQLErrors and list them here.
An empty list indicates that no GraphQL error has been sent by the API.
Set to an error, if a GraphQL request has failed outright.
A GraphQL over HTTP request may fail and not reach the API. Any error that prevents a GraphQl request outright, will be considered a “network error” and set here.
Set to the Response object a fetch exchange received.
If a built-in fetch Exchange is used in
urql, this may
be set to the Response object of the Fetch API response.
urql doesn’t assume that all users will use HTTP
as the only or exclusive transport for GraphQL this property is
neither typed nor guaranteed and may be re-used for other purposes
by non-fetch exchanges.
Hint: It can be useful to use
response.status here, however, if
you plan on relying on this being a Response in your app,
which it is by default, then make sure you add some extra checks
before blindly assuming so!
Optional override for formatting stack traces
Create .stack property on a target object
Generated using TypeDoc