File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4040 "@tailwindcss/vite" : " ^4.1.13" ,
4141 "@tanstack/react-query" : " ^5.90.1" ,
4242 "@tanstack/react-router" : " ^1.131.50" ,
43- "@tanstack/react-router-with -query" : " ^1.130.17 " ,
43+ "@tanstack/react-router-ssr -query" : " ^1.132.6 " ,
4444 "@tanstack/react-start" : " ^1.131.50" ,
4545 "class-variance-authority" : " ^0.7.1" ,
4646 "clsx" : " ^2.1.1" ,
Original file line number Diff line number Diff line change 11import { createRouter as createTanStackRouter } from "@tanstack/react-router" ;
2- import { routerWithQueryClient } from "@tanstack/react-router-with -query" ;
2+ import { setupRouterSsrQueryIntegration } from "@tanstack/react-router-ssr -query" ;
33import { QueryClient } from "@tanstack/react-query" ;
44import { routeTree } from "./routeTree.gen" ;
55
66export function createRouter ( ) {
77 const queryClient = new QueryClient ( ) ;
88
9- const router = routerWithQueryClient (
10- createTanStackRouter ( {
11- routeTree,
12- scrollRestoration : true ,
13- context : {
14- queryClient,
15- } ,
16- } ) ,
17- queryClient
18- ) ;
9+ const router = createTanStackRouter ( {
10+ routeTree,
11+ scrollRestoration : true ,
12+ context : {
13+ queryClient,
14+ } ,
15+ } ) ;
16+ setupRouterSsrQueryIntegration ( {
17+ router,
18+ queryClient,
19+ } ) ;
1920
2021 return router ;
2122}
You can’t perform that action at this time.
0 commit comments