This query string argument is looked over by * .nocache.js to force the plugin to load in the dev mode that you installed in your browser, so it connects back to the designated DevMode application.
When you need to redirect between pages, and you want them all to be executed either in dev mode or in web mode, the simplest condition is the argument condition (if possible, a value taken from an existing, rather than hard-coded) to !GWT.isProdMode() :
if (!GWT.isProdModode()) {
If you yourself do not use the query string, so it should only exist with the gwt.codesvr parameter or be absent, you can make it even simpler using UrlBuilder :
UrlBuilder builder = Window.Location.createUrlBuilder(); builder.setPath(GWT.getHostPageBaseURL() + "UserRegistration.html")
and this is not even due to the current βmodeβ in which the application is launched, as it simply unconditionally copies the query string.
Thomas Broyer
source share