Skip to content
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

IsLoading is not returned from useMutation #6478

Closed
ergi98 opened this issue Dec 3, 2023 · 1 comment
Closed

IsLoading is not returned from useMutation #6478

ergi98 opened this issue Dec 3, 2023 · 1 comment

Comments

@ergi98
Copy link

ergi98 commented Dec 3, 2023

Describe the bug

There is no isLoading variable returned from useMutation. Also the status of the query does not return loading.

Your minimal, reproducible example

.

Steps to reproduce

  1. Install
  2. Use useMutation

Expected behavior

isLoading and status of 'loading' to be returned

How often does this bug happen?

Every time

Screenshots or Videos

image image

Platform

  • OS: Mac OS Ventura 13.6

Tanstack Query adapter

react-query

TanStack Query version

v5.12.2

TypeScript version

v4.8.4

Additional context

No response

@MellKam
Copy link

MellKam commented Dec 3, 2023

If you are using version 5, you need to change isLoading and "loading" status to isPending and "pending" status in mutations.

https://tanstack.com/query/v5/docs/react/guides/migrating-to-v5#status-loading-has-been-changed-to-status-pending-and-isloading-has-been-changed-to-ispending-and-isinitialloading-has-now-been-renamed-to-isloading

@TkDodo TkDodo closed this as not planned Won't fix, can't repro, duplicate, stale Dec 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants