检测滑动是否到达底部

vue

  mounted() {
    window.addEventListener("scroll", this.handleScroll, true);
  },
   handleScroll(node) {
      let { scrollTop, clientHeight, scrollHeight } = node.target;
      console.log(scrollTop + clientHeight,'==', scrollHeight);
    },

你可能感兴趣的:(js,js)