Function: useScrollThreshold()
useScrollThreshold(
threshold):boolean
Defined in: hooks/useScrollPosition/index.ts:11
useScrollThreshold
Parameters
threshold
number
The vertical scroll position in pixels to trigger the state update.
Returns
boolean
True if the scroll position is at or past the threshold, false otherwise.
Description
Custom hook to check if the user has scrolled past a specific position.
Example
const isScrolled = useScrollThreshold(100);