beforeLoad or loader called multiple times
Hi! I'm having an issue with start and router.
If you have nested routes or pathless layouts it will call beforeLoad from the parent on each child page. Following the authentication example, we get the user inside the beforeLoad method in the __root.tsx file, then each nested route will call that server function before render
You can see the problem here: https://tanstack.com/start/latest/docs/framework/react/examples/start-basic-auth when navigating to posts it will call it 3 times before rendering
Is that expected?
If you have nested routes or pathless layouts it will call beforeLoad from the parent on each child page. Following the authentication example, we get the user inside the beforeLoad method in the __root.tsx file, then each nested route will call that server function before render
You can see the problem here: https://tanstack.com/start/latest/docs/framework/react/examples/start-basic-auth when navigating to posts it will call it 3 times before rendering
Is that expected?
An example showing how to implement Start Basic Auth in React using TanStack Start.
