@svelte-put/lockscroll
v1.0.1
Published
locking scroll and hide scrollbar within an HTML element
Downloads
440
Readme
@svelte-put/lockscroll
Svelte action use:lockscroll
- locking scroll within an HTML element
svelte-put
This package is part of the @svelte-put family. For contributing guideline and more, refer to its readme.
Usage & Documentation
See the dedicated documentation page here.
Quick Start
<script lang="ts">
import { lockscroll, createLockScrollStore } from '@svelte-put/lockscroll';
const locked = createLockScrollStore();
// ... later
locked.toggle();
</script>
<svelte:body use:lockscroll="{locked}" />