We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
If we have const [mutate, { data, error }] = useMutation(), and call mutate() alone, data, and error are populated as expected.
const [mutate, { data, error }] = useMutation()
mutate()
data
error
However, when awaiting the result of mutate like mutate().then(() => {}), data, and error are undefined.
mutate().then(() => {})
undefined
I wouldn't expect this behaviour, and cannot seem to find it documented anywhere.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
If we have
const [mutate, { data, error }] = useMutation()
, and callmutate()
alone,data
, anderror
are populated as expected.However, when awaiting the result of mutate like
mutate().then(() => {})
,data
, anderror
areundefined
.I wouldn't expect this behaviour, and cannot seem to find it documented anywhere.
The text was updated successfully, but these errors were encountered: