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

feat(v4): backport some v5 apis to v4 branch #8754

Open
wants to merge 6 commits into
base: v4
Choose a base branch
from

Conversation

danielpza
Copy link

@danielpza danielpza commented Mar 4, 2025

This is an attempt to backport some of the new api in tanstack query v5 to v4 branch, which should make it easier to developers still on v4 to migrate to v5 by making small incremental changes to the codebase without having to commit to a big change.

Apis to backport:

  • isPending alias to isLoading
  • useSuspenseQuery
  • useSuspenseQueries
  • queryOptions?
  • ...any others?
  • update documentation

Additionally this pull request adds a jsdoc @deprecated label to some of the apis that are removed/renamed in v5 and suggests some alternatives

Compared to v5, no new functionality is added, so when merging back to main discard the changes introduced in this pull request

Copy link

codesandbox-ci bot commented Mar 4, 2025

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 6923c9f:

Sandbox Source
@tanstack/query-example-react-basic-typescript Configuration
@tanstack/query-example-solid-basic-typescript Configuration
@tanstack/query-example-svelte-basic Configuration
@tanstack/query-example-vue-basic Configuration

@danielpza danielpza marked this pull request as ready for review March 4, 2025 21:31
@danielpza
Copy link
Author

Hey @TkDodo / maintainers, hope you are doing good.

Would appreciate some feedback on this, and whether this would be likely accepted or not.

Cheers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant