useResizeObserver API
API reference for the useResizeObserver composable.
Related
Explore these related pages for additional context and usage patterns.
| Page | Category |
|---|---|
| useResizeObserver | System |
| useIntersectionObserver | System |
| useMutationObserver | System |
Functions
useResizeObserver
(target: MaybeElementRef, callback: (entries: ResizeObserverEntry[]) => void, options?: ResizeObserverOptions) => UseResizeObserverReturnA composable that uses the Resize Observer API to detect when an element's size changes.
useElementSize
(target: MaybeElementRef) => UseElementSizeReturnA convenience composable that uses the Resize Observer API to track an element's size.
Options
Properties
isActive
Readonly<Ref<boolean, boolean>>Whether the observer is currently active (created and observing)