API/<TanStackRouterAdapter>
<TanStackRouterAdapter>
componentsrc/components/tanstack-router-adapter.tsx1 parameter
Make TanStack Router the router adapter of every list below it.
Render it inside the router — in the root route’s component, around its <Outlet /> — so the
lists read TanStack Router’s location and navigate through it. Only the components that use a
list re-render when the URL changes.
Import
Section titled “Import”import { TanStackRouterAdapter } from '@qubeejs/react/tanstack-router';Signature
Section titled “Signature”function TanStackRouterAdapter(props: TanStackRouterAdapterProps): ReactElementParameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
props |
TanStackRouterAdapterProps |
The subtree, and whether a list navigation scrolls to the top |
Returns
Section titled “Returns”The subtree, with the adapter in context
Example
Section titled “Example”const rootRoute = createRootRoute({ component: () => ( <TanStackRouterAdapter> <Outlet /> </TanStackRouterAdapter> ),});