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
I previously raised #19701 with a minimal reproducible example. That example was fixed but our actual use case requires a slightly more complicated reproducible example which I have attached to this ticket.
This issue is stopping us from being able to upgrade to 24.4
The example provided uses replaceState to update the URL. I think the issue also occurs when using forwarding. We switched to replaceState due to an earlier issue with PreserveOnRefresh which meant forwarding did not update the URL. Now neither mechanism works in this scenario.
In ChildRoute.java you can delete the @PreserveOnRefresh and then repeat the test and it will work as desired.
Also, when @PreserveOnRefresh is enabled, you will see that you get two beforeEnter callbacks in ChildRoute but without it enabled, you get 1 as expected.
Expected behavior
replaceState should update the URL in all instances
…#19817) (CP: 24.4) (#19844)
* Do not use callback if forward is called for PreserveOnRefresh target (#19817)
Fixes#19813
* Fix compilation error
---------
Co-authored-by: Teppo Kurki <teppo.kurki@vaadin.com>
Description of the bug
I previously raised #19701 with a minimal reproducible example. That example was fixed but our actual use case requires a slightly more complicated reproducible example which I have attached to this ticket.
This issue is stopping us from being able to upgrade to 24.4
The example provided uses replaceState to update the URL. I think the issue also occurs when using forwarding. We switched to replaceState due to an earlier issue with PreserveOnRefresh which meant forwarding did not update the URL. Now neither mechanism works in this scenario.
launch the app with:
mvn jetty:run
Navigate to:
http://localhost:8080/parent/?blah=blah
You will find that the URL changes to:
http://localhost:8080/parent/child?blah=blah
but the desired outcome is that the URL changes to:
http://localhost:8080/parent/child?corrected=true
In ChildRoute.java you can delete the @PreserveOnRefresh and then repeat the test and it will work as desired.
Also, when @PreserveOnRefresh is enabled, you will see that you get two beforeEnter callbacks in ChildRoute but without it enabled, you get 1 as expected.
Expected behavior
replaceState should update the URL in all instances
Minimal reproducible example
preserveonrefresh-issue2.zip
Versions
The text was updated successfully, but these errors were encountered: