Skip to content
🥇 [sc-react v1 alpha] A react library for creating non-rectangular/slanted container divs.
JavaScript
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
dist
src
test
.babelrc
.gitignore
.npmignore
.travis.yml
LICENSE
README.md
opt-res.gif
package-lock.json
package.json
webpack.config.js
yarn.lock

README.md

Skewed container react (sc-react)

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

Build Status npm version

Hero Image

Installation (Medium post)

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
}
You can’t perform that action at this time.