Repository navigation
fix(examples): guard against undefined loader data in route component - #1406
sentry[bot] wants to merge 1 commit into
Conversation
|
|
Important Review skippedBot user detected. To trigger a single review, invoke the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
tanstack-com | 4d6d7bc | Commit Preview URL Branch Preview URL |
Oct 20 2026, 11:16 PM |
|
Can we include a regression for the navigation that triggers this? I'd like to understand why the loader data is missing before we turn that state into an empty page.
|
During client-side navigation (e.g., transitioning from
/table/latest/docs/overviewto/table/latest/docs/framework/react/examples/basic), TanStack Router can render the destination route component while the async loader is still pending.RouteComponentwas immediately accessingdata.kindwithout checking ifdatahad resolved, throwingTypeError: can't access property "kind", r is undefined. Adding an earlyif (!data) return nullprevents the crash until the loader resolves.Fixes TANSTACK-COM-54C
@sentry <feedback>: Autofix iterates on these changes@sentry stop iterating: Autofix stops iterating on this runThis PR was automatically generated by Sentry. You can adjust this setting at any time.