How to redirect a GWT application from the client side?

As you know, res.sendRedirect (url) on the servlet side does not work, because the GWT client does not process it.

Does anyone know how to do this?

Thanks. Daniel

+4
source share
1 answer

Window.Location.assign (newUrl)

But in general, you want to avoid this because you will lose all the customer’s state. You better change the view through the code and then update the story (which updates the fragment url - the part of the url after #).

+10
source

Source: https://habr.com/ru/post/1308606/


All Articles