Skip to content
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

Use history.createLocation in <StaticRouter> #5722

Merged
merged 1 commit into from Mar 14, 2018

Conversation

pshrmn
Copy link
Contributor

@pshrmn pshrmn commented Nov 12, 2017

Currently, there is an inconsistency between the pseudo-history used by the <StaticRouter> and the histories created by the history package because the history package creates locations with decoded pathnames, while the pseudo-history does not. This PR updates the <StaticRouter> to use the createLocation function from the history package to ensure consistent decoding between <StaticRouter> and the other routers.

Fixes #5296. #5359 is also partially fixed by this, but that also includes matchPath tests which are outside the scope of this PR.

@pshrmn
Copy link
Contributor Author

pshrmn commented Mar 5, 2018

Oh bother, I messed up that conflict fix.

@timdorr
Copy link
Member

timdorr commented Mar 5, 2018

Do you have contributor commits turned on? I can try and help you out.

@pshrmn
Copy link
Contributor Author

pshrmn commented Mar 5, 2018

Thanks for the offer, but I think I got it figured out. I had re-fetched the branch, but it was rebased onto a copy of the local master, which seems to behave differently than rebasing against master.

# what I had done
git checkout -b static-history
git pull origin static-history

# what I probably should have done
git fetch origin
git checkout origin/static-history
git checkout -b static-history

TMYK

Anyways, the build issue still seems to exist, so if you don't get to it, I can probably check it out later.

@timdorr
Copy link
Member

timdorr commented Mar 5, 2018

Weird. There were no recent changes on master and everything is locked, so the last chance of breakage was whenever the lockfiles changed.

@pshrmn
Copy link
Contributor Author

pshrmn commented Mar 14, 2018

It looks like the build issues have been sorted out.

@timdorr
Copy link
Member

timdorr commented Mar 14, 2018

In she goes!

@timdorr timdorr merged commit c26c937 into remix-run:master Mar 14, 2018
@pshrmn pshrmn deleted the static-history branch March 14, 2018 04:12
@OliverJAsh
Copy link

OliverJAsh commented Mar 23, 2018

Hi, thanks for fixing this. Any ideas when this will be released? Currently, I'm having to patch React Router locally in order to apply these changes.

@timdorr
Copy link
Member

timdorr commented Mar 23, 2018

Anytime between now and the future. I've been waiting on some release tooling from Michael, but he's been busy with a few other projects.

@lock lock bot locked as resolved and limited conversation to collaborators Jun 4, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Contents of match.params differs based on containing Router
3 participants