1
0
mirror of https://github.com/ruanyf/es6tutorial.git synced 2025-05-29 05:42:20 +00:00

edit js/ditto

This commit is contained in:
ruanyf 2014-04-29 22:04:39 +08:00
parent 80e24f39de
commit 5e8394fb78

View File

@ -17,6 +17,7 @@ var ditto = {
};
var disqusCode = '<h3>留言</h3><div id="disqus_thread"></div>';
var menu;
function initialize() {
// initialize sidebar and buttons
@ -32,6 +33,14 @@ function initialize() {
init_edit_button();
}
// 初始化内容数组
var menuOL = $(ditto.sidebar+' ol');
menuOL.attr('start',0);
menuOL.find('li').map(function(){
menu.push(this.href);
});
// page router
router();
$(window).on('hashchange', router);