Blank Page on throw notFound() in beforeLoad #7470
Replies: 2 comments
-
|
I changed to errorComponent and that fixed the issue, as the api call throws an error, it's not a case of using the not found, rather the error component |
Beta Was this translation helpful? Give feedback.
-
|
This is a quirk of where Thrown from a Fix is to give the root a not-found component: export const Route = createRootRoute({
notFoundComponent: () => <div>Not found</div>,
component: RootComponent,
})or set it once on the router: const router = createRouter({
routeTree,
defaultNotFoundComponent: () => <div>Not found</div>,
})Switching to |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I have an issue where if I try this exact
loaderin abeforeLoadI get a blank page whenthrow notFound()Beta Was this translation helpful? Give feedback.
All reactions