1 | import 'intersection-observer';
|
2 | import type { BasicTarget } from '../utils/domTarget';
|
3 | type CallbackType = (entry: IntersectionObserverEntry) => void;
|
4 | export interface Options {
|
5 | rootMargin?: string;
|
6 | threshold?: number | number[];
|
7 | root?: BasicTarget<Element>;
|
8 | callback?: CallbackType;
|
9 | }
|
10 | declare function useInViewport(target: BasicTarget | BasicTarget[], options?: Options): readonly [boolean | undefined, number | undefined];
|
11 | export default useInViewport;
|