Skip to content

distributeRects()

function distributeRects(rects, axis): Rect[];

Spreads rectangles so the gaps between them are equal. Order follows position.

Parameter Type
rects Rect[]
axis "horizontal" | "vertical"

Rect[]