Problem with navigating to same route
After updating the
@tanstack/react-router
from version 1.120.13
to version 1.121.34
I have a problem when trying to navigate using to: '.'
option in navigate
from useNavigate
(for Link component works the same). From what I've been able to determine, the router tries to redirect to basepath after calling navigate with to : '.'
.
I found that this issue was related to that but it doesnt resolve my problem https://github.com/TanStack/router/pull/4472.
I prepare some demo to show the problem. To reproduce the issue go to Map and click on button open panel it than redirect you to the index route.
https://codesandbox.io/p/sandbox/tanstack-router-bug-example-j4qlpjGitHub
Build software better, together
GitHub is where people build software. More than 150 million people use GitHub to discover, fork, and contribute to over 420 million projects.

5 Replies
flat-fuchsia•2mo ago
can you please create a github issue for this?
adverse-sapphireOP•2mo ago
Sure
flat-fuchsia•2mo ago
and if you want to contribute even further, a failing unit test as a PR would be perfect
adverse-sapphireOP•2mo ago
I create an issue describing the bug https://github.com/TanStack/router/issues/4526
GitHub
Regression: navigate({ to: "." }) redirects to base path after upda...
Which project does this relate to? Router Describe the bug After updating @tanstack/react-router from version 1.120.13 to 1.121.34, I encountered a regression when navigating with navigate({ to: &q...
flat-fuchsia•2mo ago
thanks!