Rewrite URL

I want to be able to call my vaadin app using a querystring with parameters and then act upon them, if a certain action is passed. For example an externap app will call my app as follows:-

http://localhost:8282/my-app/?action=addevent#!Calendar

This works fine and i can pass ant releva variable to my calendar form. However, i then want to avoid doing this again if the browser is refreshed, so ideally, change the querystring afteri have grabbed what i need to:-

http://localhost:8282/my-app/#!Calendar

How can i achieve this?

John

I’d guess you should be able to do that with the
HTML5 History API
(in JavaScript). Something along

window.history.pushState(state, "Title", "/my-app#!Calendar") I’m not immediately sure what the state object should be there. Looks like anything works.