Skip to content

Home

Check if bottom of page is visible

Checks if the bottom of the page is visible.

const bottomVisible = () =>
  document.documentElement.clientHeight + window.scrollY >=
  (document.documentElement.scrollHeight ||
    document.documentElement.clientHeight);

bottomVisible(); // true

More like this

Start typing a keyphrase to see matching snippets.