1.0.2 • Published 4 days ago
@svelte-put/lockscroll v1.0.2
@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}" />