svelte-use-resize-observer Svelte Themes

Svelte Use Resize Observer

A simple svelte action for using `ResizeObserver`.

svelte-use-resize-observer

Usage

<script>
import resizeObserver from 'svelte-use-resize-observer'
</script>

<div use:resizeObserver on:resize={() => console.log('do something on resize')}>
   <p>Some content here...</p>
</div>

Top categories

Loading Svelte Themes