useResizeObserver()

description

  • watch the resize of the target.

demo

code

useResizeObserver({
	targetRef: targetRef,
	callback: (entry) => {
		console.log(entry)
	},
	dependencies: [],
	debounce: 100,
});