# Resize
When the size of the document flow wrapped by the component changes, it triggers the `size` event. Generally used to monitor changes in DOM dimensions and positions caused by DOM content updates, re-acquire DOM dimensions and positions, and perform calculations for content display.
## Basic Usage
> Do not add any external styles to this component
```html
```
```typescript
const width = ref('')
const height = ref('')
onReady(() => {
setTimeout(() => {
width.value = '100px'
height.value = '100px'
}, 1500)
})
function handleResize(detail: Record) {
const { height, width, top, right, bottom, left } = detail
console.log(height, width, top, right, bottom, left)
}
```
## Events
| Event Name | Description | Parameters | Version |
|------------|-------------|------------|----------|
| resize | Triggered when size changes | `{width: number, height: number, top: number, right: number, bottom: number, left: number}` | - |