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
Calling history.push or history.replace with a path that doesn't contain a search or a hash doesn't clear any existing search or hash from the location and carries them forward to the new location. This can be easily seen with the following simple test:
Calling
history.push
orhistory.replace
with a path that doesn't contain a search or a hash doesn't clear any existing search or hash from the location and carries them forward to the new location. This can be easily seen with the following simple test:The only way to circumvent this is to explicitly pass a
PartialPath
object with emptysearch
andhash
properties:This happens due to the way
getNextLocation
appends the specifiedto
location to the current location:https://github.com/ReactTraining/history/blob/28c89f4091ae9e1b0001341ea60c629674e83627/packages/history/index.ts#L479-L486
This is a regression in v5 that didn't occur with v4.
The text was updated successfully, but these errors were encountered: