html5 history api

it's funner than it sounds


wifi: guest / capstratguest



wat?



/#!/



urls matter





so what's this api thingy?





pushState()

replaceState()

popstate event






so what is state?





{ }






history.pushState(data, title, url)



enough talk,

let's fight!

(demo time)






history.pushState(data, title, url)





window.onpopstate = function(event)






history.replaceState(data, title, url)






wtf was the point of that?



demo time again

this time with more sexy




it's time to get serious

about interaction design





can't i just use a jquery plugin?





pjax


https://github.com/defunkt/jquery-pjax





questions?




thanks!


https://github.com/lesjames/history-api-demo

html history api

By Les James

html history api

  • 1,529