useInView
Track the visibility of a target element using useIntersectionObserver hook.
Scroll down!
Type Definitions
import { IntersectionObserverOptions } from '../useIntersectionObserver';
const useInView: <T extends HTMLElement = HTMLDivElement>(args: IntersectionObserverOptions<T> & {
once?: boolean;
}) => {
ref: React.RefObject<T>;
isInView: boolean;
};