GitHub 6248★

Check if user scrolls to the bottom of the page

JavaScript version

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

TypeScript version

const isAtBottom = (): boolean => document.documentElement.clientHeight + window.scrollY >= document.documentElement.scrollHeight;
Follow me on and to get more useful contents.