你的问题解决了吗?
你看看这样行不?
var $window = $(window);
var $document = $(document);
console.log($document.scrollTop());
console.log($window.height());
console.log($document.height());
$window.scroll(function(){
var preHandler = function(e){e.preventDefault();}
if ($document.scrollTop() + $window.height() + 1 >= $document.height()) {
console.log("滑到底部了");
document.addEventListener('touchmove', preHandler, false);
} else {
document.removeEventListener('touchmove', preHandler, false);
console.log("还没到底,继续滑动")
浙ICP备 15005796号-2
浙公网安备 33010602002000号
CDN 存储服务由 又拍云 赞助提供