function loadMore (nodeId,curPage,totalPage,callback) {
let box = nodeId ? document.getElementById(nodeId) : document.body;//获取监听元素
box.addEventListener("scroll", () => { // 监听滑动
const scrollTop = box.scrollTop; // 滑动距离
const scrollHeight = box.scrollHeight; // 滑动高度
const clientHeight = box.offsetHeight; // 元素视口高度
if (scrollTop + clientHeight >= scrollHeight && curPage < totalPage) {
callback && callback();
}
});
}