Skip to content

RenderBlocks

RenderBlocks<TBlock>(props): ReactNode

Defined in: packages/react/src/components/RenderBlocks.tsx:59

Dispatches a blocks-field value to per-type renderers in document order.

Replaces the hand-written switch (block.blockType) pattern. Keys are block.id — unique per entry, stable across reorders in the admin panel.

TBlock extends RenderableBlock

RenderBlocksProps<TBlock>

Blocks value, per-type renderer map, and optional fallback.

ReactNode

The rendered sequence, or null for an empty/absent array.