T
TanStack3w ago
fascinating-indigo

router.invalidate() doesn't refresh the data from Route.useLoaderData()

New to tanstack router, so I might be missing something. I have a loader on a Route that returns some data from context (e.g. auth data/logged in user). When I update the context and invalidate the router (using router.invalidate()), the TanStackRouterDevtools show the new data is in the context, and when I navigate to a new route the new data is displayed, but the data from Route.useLoaderData() isn't refreshed/updated (without a refresh or a navigation to then back to the page)
0 Replies
No replies yetBe the first to reply to this messageJoin

Did you find this page helpful?