sc-react

0.1.7 • Public • Published

Skewed container react (sc-react)

A react library for creating non-rectangular/slanted container divs.

Build Status npm version

Installation

npm install --save sc-react

or

yarn add sc-react

Adding sc-react

import SkewedContainer from 'sc-react';

Example

export default class extends React.Component{
    render(){
        return(
            <div>
                <SkewedContainer
                top="left || right"  
                bottom="left || right"
                bgColor="skyblue"  
                >
                    {/* YOUR CODE HERE */}
                </SkewedContainer>
            </div>
        )
    }
}

Properties

SkewedContainer.propTypes = {
    className: PropTypes.string,
    style: PropTypes.object,
    top: PropTypes.string,
    bottom: PropTypes.string,
    noMargin : PropTypes.bool,
    bgColor: PropTypes.string
    skew: PropTypes.Number
}

Package Sidebar

Install

npm i sc-react

Weekly Downloads

9

Version

0.1.7

License

MIT

Last publish

Collaborators

  • josephmaxim