Flex
The Flex component is a layout component that uses flexbox to layout its children.
It has a display: flex style by default.
How to use
1import { Flex } from '@devup-ui/react'
2
3function App() {
4 return <Flex />
5}
1import { Flex } from '@devup-ui/react'
2
3function App() {
4 return <Flex />
5}
The Flex component defined above will render like this:
1function App() { 2 return <div className="a" /> 3}1function App() { 2 return <div className="a" /> 3}
1/* The component's own defaults sit in a lower cascade layer, so props override them */ 2@layer b { 3 .a { 4 display: flex; 5 } 6}1/* The component's own defaults sit in a lower cascade layer, so props override them */ 2@layer b { 3 .a { 4 display: flex; 5 } 6}
Contents
Edit this page