See ResizeObserver on MDN
type resizeObserver = {}
There are methods and helpers defined in ResizeObserver .
type resizeObserverBoxOptions = | @as("border-box") BorderBox | @as("content-box") ContentBox | @as("device-pixel-content-box") DevicePixelContentBox
type resizeObserverCallback = array< resizeObserverEntry,> => resizeObserver => unit
See ResizeObserverEntry on MDN
type resizeObserverEntry = { target: WebAPI.DOMAPI.element, contentRect: WebAPI.DOMAPI.domRectReadOnly, borderBoxSize: array<resizeObserverSize>, contentBoxSize: array<resizeObserverSize>, devicePixelContentBoxSize: array<resizeObserverSize>,}
Read more on MDN
type resizeObserverOptions = { mutable box?: resizeObserverBoxOptions,}
See ResizeObserverSize on MDN
type resizeObserverSize = { inlineSize: float, blockSize: float,}