Stack

Examples

Simple Stack Layout

Secondary content
Primary Content
Secondary content
Copied to clipboard

Stack Layout With Gutter

Secondary content
Primary Content
Secondary content
Copied to clipboard

Stack Props

The Stack component accepts the following props.

NameTypeRequiredDefaultDescription
gutter
enum: sm, md, lg
nullAdds space between children. Options are sm, md or lg
children
node
nullcontent rendered inside the Stack layout
className
string
''additional classes added to the Stack layout
component
custom
'div'Sets the base component to render. defaults to div

StackItem Props

The StackItem component accepts the following props.

NameTypeRequiredDefaultDescription
isMain
bool
falseFlag indicating if this Stack Layout item contains the primary content
children
node
nulladditional classes added to the Stack Layout Item
className
string
''content rendered inside the Stack Layout Item