Implement simplehistory.js and router.js.