useInViewState(threshold?: number, untrackOnCallback?: boolean, callback?: InViewCallback)

This hook can be used to keep track of an elements in view state.

This hook is not meant for a large amount of components as it relies on state updates and not callbacks.

If you need to handle many components, register a callback through the useObserverContext hook.

© 2022
🐞

Scroll Info

Scroll Position: 0.000000000px