JavaScript监听页面滚动到底部

方法一:使用window对象的scroll事件

------ --- -
    - ------------ - ---------- -------
    - --------- - ---------- -------
    - ------------ - ------
    - ---------- - ------------ - ------------- -
        - -
        -------
    -
---

方法二:使用Intersection Observer API

- -------- - - --- --- -
    ----------- --- -
        - --------- -
            - -
            -------
        -
    ---
-- - -- - ---

- ------ - ------- - -
-------------------

方法三:检查文档高度与窗口可视区域高度之差

------ ----
    - ------------ - ---------- -------
    - --------- - ---------- -------
    - ------------ - ------
    -------------- - --------- - --------------
        - -
        -------
    -
---