@amendable/breakpoints-css

0.3.0 • Public • Published

Breakpoints CSS

This adds breakpoint support to your styles via styled-components.

Usage

import { render } from 'react-dom'
import Box, { AmendableProvider } from '@amendable/core'
import breakpointsCss from '@amendable/breakpoints-css'
import inlinePropsCss from '@amendable/inline-props-css'

render(
  <AmendableProvider
    resolvers={[
      breakpointsCss(),
      inlinePropsCss()
    ]}
  >
    <Box color={{ xs: 'red', lg: 'blue' }}>
      This will be red on small screens and blue on desktops+.
    </Box>
  </AmendableProvider>
)

Supported props

It supports all props.

/@amendable/breakpoints-css/

    Package Sidebar

    Install

    npm i @amendable/breakpoints-css

    Weekly Downloads

    6

    Version

    0.3.0

    License

    MIT

    Unpacked Size

    20.6 kB

    Total Files

    8

    Last publish

    Collaborators

    • jpalumickas
    • nedomas
    • saimis