router
router copied to clipboard
Dynamic invoice route in kitchen sink examples break (`could not find match...`)
Describe the bug
When you open one of the kitchen sink examples, the route breaks when you navigate to the invoices. Given the fact that I experience issues with dynamic routes in another codebase (that I haven't been able to succesfully reproduce in a small reproduction) this may indicate there's an underlying bug.
Your Example Website or App
https://stackblitz.com/github/tanstack/router/tree/main/examples/react/kitchen-sink-file-based?embed=1&theme=light&preset=node&file=src/main.tsx
Steps to Reproduce the Bug or Issue
- Open the official kitchen-sink example.
- Click on Dashboard › Invoices › select an invoice.
- Note that the invoice is loaded and the url is updated properly.
- Click on 'Home'.
- Click on Dashboard › Invoices › select an invoice.
- Note that the invoice is NOT loaded and the URL is NOT updated properly (flips back to /invoices).
- The error displayed in the console says: "Could not find match for from: /dashboard/invoices/$invoiceId"
Expected behavior
As a user I expect the route to be properly loaded the second time also.
Screenshots or Videos
https://github.com/TanStack/router/assets/487182/60e99303-744c-4811-9a12-9396a265cc65
Platform
- OS: macOS
- Browser: All
Additional context
No response