Skip to content

Commit 1dc32f0

Browse files
committed
Merge branch 'main' into test/react-query-ssr-mutation
2 parents e72096f + 642f72d commit 1dc32f0

File tree

95 files changed

+795
-190
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

95 files changed

+795
-190
lines changed

.github/workflows/pr.yml

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -60,16 +60,12 @@ jobs:
6060
id: determine-sha
6161
run: |
6262
echo "COMMIT_SHA=${{ github.event.pull_request.head.sha || github.sha }}" >> $GITHUB_ENV
63-
- name: Preview Bundle Size
64-
uses: marocchino/sticky-pull-request-comment@fd19551a2a7c0d29677c63257f86d8ef8bb24b48
63+
- name: Size Limit
64+
uses: andresz1/size-limit-action@94bc357df29c36c8f8d50ea497c3e225c3c95d1d
6565
with:
66-
message: |
67-
Sizes for commit ${{ env.COMMIT_SHA }}:
68-
| Branch | Bundle Size |
69-
|--------|--------|
70-
| Main | [![](https://deno.bundlejs.com/badge?q=https://esm.sh/@tanstack/react-query/es2022/react-query.mjs&config={%22esbuild%22:{%22external%22:[%22react@^19.2.1/jsx-runtime?target=es2022%22,%22react@^19.2.1?target=es2022%22]}}&badge=detailed)](https://bundlejs.com/?q=https://esm.sh/@tanstack/react-query/es2022/react-query.mjs&config=%7B%22esbuild%22:%7B%22external%22:%5B%22react@%5E19.2.0/jsx-runtime?target=es2022%22,%22react@%5E19.2.0?target=es2022%22%5D%7D%7D) |
71-
| This PR | [![](https://deno.bundlejs.com/badge?q=https://esm.sh/pr/@tanstack/react-query@${{ env.COMMIT_SHA }}/es2022/react-query.mjs&config={%22esbuild%22:{%22external%22:[%22react@^19.2.1/jsx-runtime?target=es2022%22,%22react@^19.2.1?target=es2022%22]}}&badge=detailed)](https://bundlejs.com/?q=https://esm.sh/pr/@tanstack/react-query@${{ env.COMMIT_SHA }}/es2022/react-query.mjs&config=%7B%22esbuild%22:%7B%22external%22:%5B%22react@%5E19.2.0/jsx-runtime?target=es2022%22,%22react@%5E19.2.0?target=es2022%22%5D%7D%7D) |
72-
continue-on-error: true
66+
github_token: ${{ secrets.GITHUB_TOKEN }}
67+
skip_step: install
68+
build_script: build:all
7369
provenance:
7470
name: Provenance
7571
runs-on: ubuntu-latest

.size-limit.json

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
[
2+
{
3+
"name": "react full",
4+
"path": "packages/react-query/build/modern/index.js",
5+
"limit": "12.10 kB",
6+
"ignore": ["react", "react-dom"]
7+
},
8+
{
9+
"name": "react minimal",
10+
"path": "packages/react-query/build/modern/index.js",
11+
"limit": "9.11 kB",
12+
"import": "{ useQuery, QueryClient, QueryClientProvider }",
13+
"ignore": ["react", "react-dom"]
14+
}
15+
]

docs/framework/react/guides/scroll-restoration.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,6 @@ title: Scroll Restoration
55

66
Traditionally, when you navigate to a previously visited page on a web browser, you would find that the page would be scrolled to the exact position where you were before you navigated away from that page. This is called **scroll restoration** and has been in a bit of a regression since web applications have started moving towards client side data fetching. With TanStack Query however, that's no longer the case.
77

8+
TanStack Query doesn’t implement scroll restoration by itself, but it removes one of the biggest causes of broken restoration in SPA’s: refetch-induced UI resets. By keeping previously fetched data in cache (and optionally using `placeholderData`), navigation back to a page can render instantly with stable layout, making scroll restoration reliable when handled by the router (e.g. React Router’s ScrollRestoration, TanStack Router’s scroll restoration, or a small custom history-based solution).
9+
810
Out of the box, "scroll restoration" for all queries (including paginated and infinite queries) Just Works™️ in TanStack Query. The reason for this is that query results are cached and able to be retrieved synchronously when a query is rendered. As long as your queries are being cached long enough (the default time is 5 minutes) and have not been garbage collected, scroll restoration will work out of the box all the time.

examples/angular/auto-refetching/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"@angular/compiler": "^20.0.0",
1414
"@angular/core": "^20.0.0",
1515
"@angular/platform-browser": "^20.0.0",
16-
"@tanstack/angular-query-experimental": "^5.90.16",
16+
"@tanstack/angular-query-experimental": "^5.90.17",
1717
"rxjs": "^7.8.2",
1818
"tslib": "^2.8.1",
1919
"zone.js": "0.15.0"

examples/angular/basic-persister/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@
1313
"@angular/compiler": "^20.0.0",
1414
"@angular/core": "^20.0.0",
1515
"@angular/platform-browser": "^20.0.0",
16-
"@tanstack/angular-query-experimental": "^5.90.16",
17-
"@tanstack/angular-query-persist-client": "^5.62.19",
18-
"@tanstack/query-async-storage-persister": "^5.90.14",
16+
"@tanstack/angular-query-experimental": "^5.90.17",
17+
"@tanstack/angular-query-persist-client": "^5.62.20",
18+
"@tanstack/query-async-storage-persister": "^5.90.15",
1919
"rxjs": "^7.8.2",
2020
"tslib": "^2.8.1",
2121
"zone.js": "0.15.0"

examples/angular/basic/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"@angular/compiler": "^20.0.0",
1414
"@angular/core": "^20.0.0",
1515
"@angular/platform-browser": "^20.0.0",
16-
"@tanstack/angular-query-experimental": "^5.90.16",
16+
"@tanstack/angular-query-experimental": "^5.90.17",
1717
"rxjs": "^7.8.2",
1818
"tslib": "^2.8.1",
1919
"zone.js": "0.15.0"

examples/angular/devtools-panel/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"@angular/core": "^20.0.0",
1515
"@angular/platform-browser": "^20.0.0",
1616
"@angular/router": "^20.0.0",
17-
"@tanstack/angular-query-experimental": "^5.90.16",
17+
"@tanstack/angular-query-experimental": "^5.90.17",
1818
"rxjs": "^7.8.2",
1919
"tslib": "^2.8.1",
2020
"zone.js": "0.15.0"

examples/angular/infinite-query-with-max-pages/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"@angular/compiler": "^20.0.0",
1414
"@angular/core": "^20.0.0",
1515
"@angular/platform-browser": "^20.0.0",
16-
"@tanstack/angular-query-experimental": "^5.90.16",
16+
"@tanstack/angular-query-experimental": "^5.90.17",
1717
"rxjs": "^7.8.2",
1818
"tslib": "^2.8.1",
1919
"zone.js": "0.15.0"

examples/angular/optimistic-updates/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"@angular/core": "^20.0.0",
1515
"@angular/forms": "^20.0.0",
1616
"@angular/platform-browser": "^20.0.0",
17-
"@tanstack/angular-query-experimental": "^5.90.16",
17+
"@tanstack/angular-query-experimental": "^5.90.17",
1818
"rxjs": "^7.8.2",
1919
"tslib": "^2.8.1",
2020
"zone.js": "0.15.0"

examples/angular/pagination/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"@angular/compiler": "^20.0.0",
1414
"@angular/core": "^20.0.0",
1515
"@angular/platform-browser": "^20.0.0",
16-
"@tanstack/angular-query-experimental": "^5.90.16",
16+
"@tanstack/angular-query-experimental": "^5.90.17",
1717
"rxjs": "^7.8.2",
1818
"tslib": "^2.8.1",
1919
"zone.js": "0.15.0"

0 commit comments

Comments
 (0)