In v5 we could pass a function (which would receive a location param) to the to prop. This no longer seems to be supported in v6, judging by the types:
There doesn't seem to be any mention of this breaking change in the migration guide? Is it intentionally left out or do you plan to restore it for v6? FWIW I found this very useful, so that components don't have to manually read the location. IIRC there is more justification for this feature in the PR which initially added it in v5.
https://github.com/ReactTraining/react-router/pull/5368
https://github.com/ReactTraining/react-router/issues/5331
Oh, no, not again 🤦🏻♂️ Last time it took two years to merge my PR for v5, which implemented this functionality.
Can we get a PR to add it back? V6 is a rewrite, which is why it didn't come over.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
You can add the fresh label to prevent me from taking any action.
We should keep this open because it represents a breaking change and many people could be affected.
Most helpful comment
Oh, no, not again 🤦🏻♂️ Last time it took two years to merge my PR for v5, which implemented this functionality.