Skip to content

Instantly share code, notes, and snippets.

@tlrobinson
Created May 27, 2011 23:17
Show Gist options
  • Save tlrobinson/996381 to your computer and use it in GitHub Desktop.
Save tlrobinson/996381 to your computer and use it in GitHub Desktop.
Hack to make NewTwitter use HTML5 pushState instead of annoying hash fragments.
twttr.secrets.html5Routing = true;
twttr.router._changeUrlAndCallAction = function(p) {
return twttr.Router.prototype._changeUrlAndCallAction.call(this, p.replace("#!/", ""));
}
twttr.router._changeUrlAndCallAction(window.location.hash);
@ravikiranj
Copy link

deadly !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment