react-query-questions
solid-query-questions
table-questions
virtual-questions
router-questions
react-charts-questions
ranger-questions
vue-query-questions
svelte-query-questions
bling-questions
form-questions
angular-query-questions
start-questions
db-questions
start-showcase
router-showcase
📣-announcements
HTTP Session Cookie
Router Loaders parallelism in a CRM app project
/entity/$entityId/entityBs
or /entity/$entityId/entityBs/$entityBId
. My problem is what is $entityId
does not exists server-side, all the loaders of the child routes still gets executed for no reason since we know the parent does not exist.
Any advices? Should I only be using loaders for my top-level entity page and not for nested routes?
...Best practices for combining tanstack router context + tanstack query [React, Typescript]?
Can I have server only context that i can access in my router ?
Can I make a common loader for few components?

Route
Syncronously getting url
My use case is this. I have a form submit to a database that may take some time to resolve. When the request resolves I navigate the user to a new page. But, if while the request is resolving (could take a few seconds) the user manually navigates to another page in the app, I don't want to navigate them to the new page when the request resolves.
Since the value returned from
useLocation
is stateful, it's value is stale if the user manually navigates while the request is resolving. Is there a way to call getLocation
once the request resolves so I can check if the user has navigated while the request was resolving?...onCatch not getting fired if no errorComponent is present on a route
errorComponent
defined at _root
level which acts as a fallback "catch-all-errors" component.
An inner route that doesn't expose any error components is throwing an error via tanstack-query's throwOnError
: I'd like to use the onCatch
method to evaluate the error and eventually clear any invalid search parameters. However, the method doesn't get fired unless there's an errorComponent
defined on that route, so I'm stuck going back all the way the fallback on __root and cannot access the route's onCatch
method.
Is this the expected behaviour, or should the onCatch
method get fired anyway?...If no "to" prop is present navigate({search}) results typescript error

Can I matchRoute on a wildcard path?
addFileChildren not a function
Is there a way to cancel a navigation event in Route.beforeLoad?
combining react query and defer
articles
and tags
however I don't want to wait for the tags
to load before displaying the articles.
Is this the correct way to combine react query
, ensureQueryData
and defer
to achieve this result?
The full sandbox is here:...Re fetching with React Query when the URL changes?
Cookie based authentication approach
beforeLoad
function like this:
login.tsx
```ts...Best way to do optional path params (for i18n)? Virtual routes?
/todos/:id
should be identical to /en/todos/:id
if en
is the fallback language, otherwise prefixes are specified for all other languages. Is there a way to achieve this with router?
We've been trying with virtual routes, but it seems codegen goes all over the place when you combine root-level virtual routes with Tanstack Start. With every combination we tried the codegen hangs trying to generate routes....How to use context data in a loader

Persist URL Parameter Across Navigations
Importing generated router file causes nitro startup error