You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Browser only preserves scrolling position when you go Back or Forward.
If you open the same link twice, browser will scroll it to top.
However, react-router seems to always remember scroll position for every URL.
This means if you scrolled some page, it will forever open scrolled from now on.
I believe react-router should only attempt restoring scroll position if path changed due to popstate, and not due to pushstate.
The text was updated successfully, but these errors were encountered:
@gaearon I opened #252 to try and nail down the cases where we're scrolling and we shouldn't be, but so far that ticket only mentions clicking on links. Is that what you mean by "open the same link twice"? Or are you doing that via back/forward buttons?
Browser only preserves scrolling position when you go Back or Forward.
If you open the same link twice, browser will scroll it to top.
However, react-router seems to always remember scroll position for every URL.
This means if you scrolled some page, it will forever open scrolled from now on.
I believe react-router should only attempt restoring scroll position if path changed due to popstate, and not due to pushstate.
The text was updated successfully, but these errors were encountered: