---
category: Elements
---
# useResizeObserver
Reports changes to the dimensions of an Element's content or the border-box
## Usage
```vue
{{ text }}
```
## Directive Usage
```vue
{{ text }}
```
[ResizeObserver MDN](https://developer.mozilla.org/en-US/docs/Web/API/ResizeObserver)
## Type Declarations
```ts
/**
* @deprecated This interface is now available in the DOM lib.
* Use the global {@link globalThis.ResizeObserverSize} instead.
*/
export interface ResizeObserverSize {
readonly inlineSize: number
readonly blockSize: number
}
/**
* @deprecated This interface is now available in the DOM lib.
* Use the global {@link globalThis.ResizeObserverEntry} instead.
*/
export interface ResizeObserverEntry {
readonly target: Element
readonly contentRect: DOMRectReadOnly
readonly borderBoxSize: ReadonlyArray
readonly contentBoxSize: ReadonlyArray
readonly devicePixelContentBoxSize: ReadonlyArray
}
/**
* @deprecated This interface is now available in the DOM lib.
* Use the global {@link globalThis.ResizeObserverCallback} instead.
*/
export type ResizeObserverCallback = (
entries: ReadonlyArray,
observer: ResizeObserver,
) => void
export interface UseResizeObserverOptions
extends ResizeObserverOptions,
ConfigurableWindow {}
/**
* Reports changes to the dimensions of an Element's content or the border-box
*
* @see https://vueuse.org/useResizeObserver
* @param target
* @param callback
* @param options
*/
export declare function useResizeObserver(
target:
| MaybeComputedElementRef
| MaybeComputedElementRef[]
| MaybeRefOrGetter,
callback: globalThis.ResizeObserverCallback,
options?: UseResizeObserverOptions,
): {
isSupported: ComputedRef
stop: () => void
}
export type UseResizeObserverReturn = ReturnType
```