-
-
Notifications
You must be signed in to change notification settings - Fork 10.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Redirect is not computing the params from the from
path to the to
path
#5753
Comments
This should be working, but I think Redirect is not receiving the This prop should be passed by Switch to the Redirect but it seems something is buggy and this isn't happening. |
Currently I'm doing this as a workaround: #4919 (comment) |
I believe this is the feature that you're referring to #5209. It has been merged, but there hasn't been a release since then. |
@pshrmn Oooooh. Looking forward to it! Thanks :) |
Version
4.2.2
Test Case
Code: https://github.com/Sparragus/react-router-redirect-bug/blob/master/src/App.js
Demo: https://redirect-bug-cbfahyusjk.now.sh/
Steps to reproduce
/users
(This is expected behavior)/users/sparragus
. (This is expected behavior)/users
/profile/horse_js
to/users/horse_js
. However, you will be redirected to/users/:username
. (This is unexpected behavior).Expected Behavior
When clicking on the link to @horse_js's profile at
/users
, you are redirected from/profile/horse_js
to/users/horse_js
.Actual Behavior
When clicking on the link to @horse_js's profile
/users
, you are redirected from/profile/horse_js
to/users/:username
.The text was updated successfully, but these errors were encountered: