--- category: Sensors --- # useScrollLock Lock scrolling of the element. ## Usage ```vue ``` ## Directive Usage ```vue ``` ## Type Declarations ```ts /** * Lock scrolling of the element. * * @see https://vueuse.org/useScrollLock * @param element */ export declare function useScrollLock( element: MaybeRefOrGetter, initialState?: boolean, ): WritableComputedRef; ```