@real-system/box-primitive
v0.0.24
Published
A basic div with style props that should be used to build other components
Downloads
27
Maintainers
Readme
Usage
Installation
# install peer dependencies
# npm
$ npm install --save @real-system/styled-library react react-dom
# yarn
$ yarn add @real-system/styled-library react react-dom
# install box
# npm
$ npm install --save @real-system/box-primitive
# yarn
$ yarn add @real-system/box-primitive
Code Example
import { ThemeProvider } from '@real-system/styled-library';
import { Box, BoxAs } from '@real-system/box-primitive';
const Aside = BoxAs('aside');
const MyComponent = () => {
return (
<ThemeProvider>
<Aside background="white" display="flex" flexDirection="column">
<Box display="flex">...</Box>
</Aside>
</ThemeProvider>
);
};