获取信息以后,再执行实例化即可
//获取信息
loadList();
//实例化
mui.init();
mui.ready(function () {
var header = document.querySelector('header.mui-bar');
var list = document.getElementById('list');
//calc hieght
list.style.height = (document.body.offsetHeight - header.offsetHeight) + 'px';
//create
window.indexedList = new mui.IndexedList(list);
});
网友评论