DEV Community

Alexander Nedomansky
Alexander Nedomansky

Posted on

Resize Observer API

This is a submission for DEV Challenge v24.03.20, One Byte Explainer: Browser API or Feature.

Explainer

The Resize Observer API is used to react to an element's changes in size. It is one of many Observers and provides an easy to use solution in comparison to otherwise problematic approaches.
Use with new ResizeObserver(cb)+ ResizeObserver.observe(el).

Additional Context

Top comments (0)