1.0.1 • Published 4 years ago

@markdijkstra/react-placeholder v1.0.1

Weekly downloads
1
License
(MIT OR Apache-2....
Repository
github
Last release
4 years ago

react-placeholder

npm NPM GitHub issues CircleCI

React component which allows you to create dummy placeholders.

How install

npm i @markdijkstra/react-placeholder

How to use

import {Placeholder} from '@markdijkstra/react-placeholder'


const PlaceholderData = [
    {
        height          : '150px',
        width           : '300px',
        backgroundColor : '#eee',
        borderColor     : '#ccc',
        textColor       : '#aaa',
        fontSize        : '13px',
        caption         : 'placeholder caption'
    }
];

<Placeholder options={PlaceholderData} className="my-placeholder"/>

Options

optiondefault
height150px
width300px
backgroundColor#eee
borderColor#ccc
textColor#aaa
fontSize13px
captionheight x width

The value caption can be removed by setting it to 'false'.