Faster history.replaceState.

Issue #2 specified the script to be injected only after the DOM is parsed, because it was using the title of the window as a parameter which can be either specified/not specified/changed at the moment. This pull request eliminates the use of the title, and tries to inject the script before the parsing.