Skip to main content

Flex

Import

import { Flex } from "@sparrowengg/twigs-react";

Flex is a wrapper around HTML element div, but comes with flexbox properties.

Usage

Result
Loading...
<Flex flexDirection="column" gap="$8"> 
  <p> Hello </p>
  <p> World </p>
</Flex>

Props

PropertyDescriptionTypeDefault
flexDirectionrow
justifyContentnormal
alignItemsnormal
alignContentnormal
justifyItemslegacy
wrapnowrap
grow0
gap
shrink1
flow
basisauto