Conversation
…e old options - Updated dependencies for @tanstack/react-query and related packages to version 4.40.0 in pnpm-lock.yaml and pnpm-workspace.yaml. - Adjusted peer dependencies in package.json to reflect the new version. - Deprecated certain options and types in the react-query-4 package to align with the latest API changes. - Updated tests to accommodate changes in type expectations and removed unused imports. Co-authored-by: halfstack <61955474+ha1fstack@users.noreply.github.com>
🦋 Changeset detectedLatest commit: 9d2e076 The changes in this PR will be included in the next version bump. This PR includes changesets to release 7 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
People can be co-author:
|
|
Size Change: -1.05 kB (-1.65%) Total Size: 62.8 kB
ℹ️ View Unchanged
|
… usePrefetchQuery tests - Changed import statements in PrefetchQuery.test-d.tsx and usePrefetchQuery.test-d.tsx to source queryOptions from @tanstack/react-query instead of local files. - This aligns the tests with the updated package structure following the recent dependency updates.
…tack/react-query - Removed the local import of queryOptions and replaced it with the import from @tanstack/react-query to ensure consistency with the updated package structure.
gwansikk
left a comment
There was a problem hiding this comment.
The day has finally come when it is officially supported. It's a historic day. 그동안의 여정의 결과, 멋있습니다. 계속 킵고잉하시죠!! Suspensive!
| * @deprecated Use `queryOptions` from \@tanstack/react-query@^4.40.0 | ||
| * @example |
There was a problem hiding this comment.
| * @deprecated Use `queryOptions` from \@tanstack/react-query@^4.40.0 | |
| * @example | |
| * @deprecated Use `queryOptions` from \@tanstack/react-query@^4.40.0 | |
| * @see (If a migration guide becomes available later.) | |
| * @example |
this is a suggestion
ha1fstack
left a comment
There was a problem hiding this comment.
Amazing work as always, thank you for prompt update!
| const [ | ||
| query1, | ||
| query2, | ||
| // query3 | ||
| ] = useQueries({ | ||
| queries: [ | ||
| query.options1(), | ||
| { ...query.options2() }, | ||
| queryOptions({ | ||
| queryKey: [...queryKey, 4] as const, | ||
| queryFn: () => Promise.resolve({ field: 'success' }), | ||
| select: (data) => { | ||
| expectTypeOf(data).toEqualTypeOf<{ field: string }>() | ||
| return data.field | ||
| }, | ||
| }), | ||
| // queryOptions({ | ||
| // queryKey: [...queryKey, 4] as const, | ||
| // queryFn: () => Promise.resolve({ field: 'success' }), | ||
| // select: (data) => { | ||
| // expectTypeOf(data).toEqualTypeOf<{ field: string }>() | ||
| // return data.field | ||
| // }, | ||
| // }), | ||
| ], | ||
| }) | ||
| expectTypeOf(query1).toEqualTypeOf<UseQueryResult<{ field: string }>>() | ||
| expectTypeOf(query1.data).toEqualTypeOf<{ field: string } | undefined>() | ||
| expectTypeOf(query2).toEqualTypeOf<UseQueryResult<{ field: string }>>() | ||
| expectTypeOf(query2.data).toEqualTypeOf<{ field: string } | undefined>() | ||
| expectTypeOf(query3).toEqualTypeOf<UseQueryResult<string>>() | ||
| expectTypeOf(query3.data).toEqualTypeOf<string | undefined>() | ||
| // expectTypeOf(query3).toEqualTypeOf<UseQueryResult<string>>() | ||
| // expectTypeOf(query3.data).toEqualTypeOf<string | undefined>() |
There was a problem hiding this comment.
Any reason for commenting out instead of removing it?


PeerDep @tanstack/react-query to version 4.40.0 and deprecate old options
@ha1fstack (issue reporter), could you review these changes, please?
Next thing to do: TanStack/query#9334
After several years of polishing the Suspensive React Query interface — from raising the first issue to this PR and finally merging into TanStack Query v4 — it feels like we’re nearing the end of a long journey of Suspensive React Query. 감성적이게 되는 날입니다 🥲
PR Checklist