Skip to content
nexubDesign System
v12.7.0

Components · Layout

Grid

StableAdded v0.0.1

CSS Grid layout primitive.

import { Grid } from '@nexub/react';
View as Markdown

Playground

Props

Card 1

Card 2

Card 3

Card 4

TSX
<Grid cols={2} gap="md" className="w-full max-w-100">…</Grid>

Examples

2-column

Card 1

Card 2

Card 3

Card 4

3-column

Item 1

Item 2

Item 3

Item 4

Item 5

Item 6

Props

Props
PropTypeDefaultDescription
colsstring | number—Number of columns or a custom grid-template-columns value.
gapstring | number—Gap between grid cells using design tokens.
asChildbooleanfalse
flow'row' | 'column' | 'dense'—
rowsstring | number—

On iOS & Android