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
The handling of params-only paths added in 0.14.3 is broken. In some situations redirects caused by setSearchParams ends up on the previous page than the one it's started from, as if back was clicked.
You start on the /a page, click the link to go to /b, then the link to go back etc.
On solid-router 0.14.3 going from /a to /b seems not to work (this is visible on the first or on the second round).
Expected behavior
On solid-router 0.14.2 it work fine, going between the two pages. This is correct.
Screenshots or Videos
No response
Platform
OS: Windows
Browser: Chrome
Version: 127.0.6533.120
Additional context
The resolvedTo variable is set to resolvePath((queryOnly && (s = source().value) && s.split("?")[0]) || "", to) in this case. I don't understand the purpose of this expression, but the result is that it is set to the source, which is the previous page, at least in some situations. This seems to be causing the problems.
The text was updated successfully, but these errors were encountered:
Yeah it's because the source hasn't been updated yet (that happens at the end) and it is trying to navigate while in the middle of another navigation and reading the outdated value. Thanks for bringing this to my attention.
Describe the bug
The handling of params-only paths added in 0.14.3 is broken. In some situations redirects caused by
setSearchParams
ends up on the previous page than the one it's started from, as if back was clicked.Your Example Website or App
https://stackblitz.com/edit/tanstack-query-2qepsz?file=src%2Findex.tsx
Steps to Reproduce the Bug or Issue
You start on the /a page, click the link to go to /b, then the link to go back etc.
On solid-router 0.14.3 going from /a to /b seems not to work (this is visible on the first or on the second round).
Expected behavior
On solid-router 0.14.2 it work fine, going between the two pages. This is correct.
Screenshots or Videos
No response
Platform
Additional context
The
resolvedTo
variable is set toresolvePath((queryOnly && (s = source().value) && s.split("?")[0]) || "", to)
in this case. I don't understand the purpose of this expression, but the result is that it is set to the source, which is the previous page, at least in some situations. This seems to be causing the problems.The text was updated successfully, but these errors were encountered: