Row
<Row> is the layout container. It must be a direct child of a root wrapper (<Email>, <Page>, <Document>, or <Body>).
Props
| Prop | Type | Default |
|---|---|---|
layout | ColumnLayout | — |
cells | number[] | [1] (single column) when neither layout nor cells is given |
backgroundColor | string | — |
padding | string | "0px" |
noStackMobile | boolean | false |
Multi-column rows stack vertically on narrow viewports by default. Set noStackMobile={true} to keep them side-by-side.
If you supply layout, the library calls validateColumnLayout on the children at render time. Passing the wrong number of <Column> children throws.
Example
<Row layout={ColumnLayouts.TwoEqual} backgroundColor="#ffffff" padding="20px">
<Column>{/* ... */}</Column>
<Column>{/* ... */}</Column>
</Row>
See Also
- Column — what goes inside a row.
- ColumnLayouts — available layout presets.
- Limitations — column count mismatches and other common mistakes.