Closed jexodusmercado closed 2 weeks ago
Same as #1537.
I think this is also the same with #1528. Downgraded to 1.28.1 to make it work for now.
Seems like an unfortunate time to checkout the project. I set it up yesterday, file base routing.
I have an /
index route and a /login
route and made it so that the index route always redirects to the login route via beforeLoad
and throw redirect(...)
, just to try things and it just wouldn't work.
upon accessing the /
route, the url shows /login
but the displayed component is the one from the index route :(
Upon reloading (browser url shows /login
) it only then shows the component for the /login
route.
@tmkn Unfortunate indeed as I'm currently fixing this issue!
@tannerlinsley all good, I saw you were working on it, updating to 1.31.4
fixed some of the issues like redirecting from /foo
to /login
.
I like the type safety of the routes and its not urgent to have it working, will most likely stick with it anyway once it's working, I like what I've seen so far :)
Tanner has fixed this and it's available in 1.31.5 release.
Describe the bug
I am using the version 1.31.3 in my repository. Redirect is not working properly if I enter the URL directly inside instead of navigating thru UI. Sample authentication repo also has this bug.
Your Example Website or App
https://codesandbox.io/p/devbox/github/tanstack/router/tree/main/examples/react/authenticated-routes?embed=1&file=%2Fsrc%2Froutes%2F_auth.tsx%3A22%2C5&theme=light
Steps to Reproduce the Bug or Issue
Expected behavior
As a user, I should be redirected to the correct screen. In this case, I am able to view the protected routes even if I am not yet authenticated.
Screenshots or Videos
No response
Platform
Additional context
No response