close

Filter

loading table of contents...

Headless Server Developer Manual / Version 2010

Table Of Contents

12.2.3.2 PageGrid Component

The PageGrid component now iterates over the rows and their containing placements, to structure the content into several PageGridPlacement components. The key parameter is required by React to have a unique identifier for rendering multiple of the same component at once.

function PageGrid(props) {
  const rows = props.rows || [];
  return (
    <>
      {rows.map((row) =>
        row.placements.map(
          (placement) =>
            placement && <PageGridPlacement key={placement.name} {...placement} />
        )
      )}
    </>
  );
}

Example 12.6. Iterating over all rows of the PageGrid


Search Results

Table Of Contents