layout-primitives

2.0.0 • Public • Published

Layout Primitives built using Emotion and React

Implementation:

  1. yarn add layout-primitives emotion theme-provider
  2. Add emotion to .babelrc
  3. Add the ThemeProvider at the top level of your app, with the theme function from utils
  4. Make awesome things

Usage:

 
import { ThemeProvider, withTheme } from 'theme-provider';
import { Container, makeTheme } from 'layout-primitives';
 
const Wrapper = withTheme(Container);
 
const App = () => (
  <ThemeProvider theme={...makeTheme()}>
    <Wrapper>
      <h1>Hello World</h1>
    </Wrapper>
  </ThemeProvider>
);

Package Sidebar

Install

npm i layout-primitives

Weekly Downloads

2

Version

2.0.0

License

MIT

Last publish

Collaborators

  • matthamlin