locate=$(document).height()-$(window).height() times=0 scroller = (cb)-> if locate<=$(document).height()-$(window).height() times=0 locate+=100 scroll(0,locate) clearTimeout(timer) timer=setTimeout("scroller()",54) timer else await sleep 3000, defer() times++ console.log times return if times>3 scroller() scroller()
原文地址:https://www.cnblogs.com/heiyou-blog/p/9442344.html
时间: 2024-10-28 21:41:32