class-props

1.0.0 • Public • Published

class-props

React component for quickly applying multiple classNames – great for libraries like Tachyons and Basscss

npm i class-props
import React from 'react'
import Base from 'class-props'

const App = props => (
  <React.Fragment>
    <link ref='stylesheet' href='https://unpkg.com/basscss@8.0.2/css/basscss.min.css' />
    <Base px3 py4>
      <Base is='h1' h1>
        Hello
      </Base>
    </Base>
  </React.Fragment>
)
// Creating a style component
const Heading = props =>
  <Base
    is='h2'
    {...props}
    h2
    mt3
    mb2
  />

MIT License

Readme

Keywords

none

Package Sidebar

Install

npm i class-props

Weekly Downloads

2

Version

1.0.0

License

MIT

Last publish

Collaborators

  • jxnblk