For AI agents: the documentation index is at llms.txt. Markdown versions are available by appending .md to any page URL, including this page's markdown.
useContainerWidth
Measure and track container width.
DndGrid and ResponsiveDndGrid measure container width automatically. Use
useContainerWidth when you need the width for custom constraints or to drive
DndGrid/useDndGrid directly.
Example
import { useState } from "react";
import { DndGrid, type Layout, useContainerWidth } from "@dnd-grid/react";
import "@dnd-grid/react/styles.css";
const
Published with Edda