/*global document, window */
'use strict';

module.exports = (function() {
  var $ = require('jquery');
  var views = require('./views');
  var Router = require('routes');

  var router = new Router();

  router.browserStart = function() {
    $('body').on("click", "[href^='#/']", function(e) {
      e.preventDefault();

      var path = document.location.hash.replace('#\/', '');
      var match = router.match(path);

      match.fn(match, callback);

    });
  };

  router.addRoute('^[^/]+*/[^/]+$', views.display_homepage
  router.addRoute('^$', views.display_homepage);

  return router;

})();

@@ -453,17 +453,180 @@
 );%0A%0A    
-%7D
+  history.pushState(0, 0, path);%0A    %7D);%0A    var path = document.location.hash.replace('#%5C/', '');%0A    var match = router.match(path);%0A%0A    match.fn(match, callback
 );%0A  %7D;%0A

add to history, run on page load in browser