1.1.1 • Published 7 years ago

react-placeholder-componenet v1.1.1

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

Placeholder Image Examples

Build Status Dependencies Dev Dependencies Known Vulnerabilities NPM Downloads

React Placeholder Component 📌

React component that creates placeholder images for your project in progress. Inject placeholder images form a varierty of popular services with ease.

Install

npm install react-placeholder-componenet --save

General Usage

import ImagePlaceholder from 'react-placeholder-componenet';
<ImagePlaceholder source="baconMockup" width="450" height="310" />

The above will result in <img src="http://baconmockup.com/220/200" width="450" height="310" alt="baconMockup"> being rendered on the view. Plays well with create-react-app 🎉

Placeholder Sources

<ImagePlaceholder source="unsplashIt" />
<ImagePlaceholder source="placeHolder" />
<ImagePlaceholder source="placeImg" />
<ImagePlaceholder source="placeImgAnimals" />
<ImagePlaceholder source="placeImgArch" />
<ImagePlaceholder source="placeImgNature" />
<ImagePlaceholder source="placeImgPeople" />
<ImagePlaceholder source="placeImgTech" />
<ImagePlaceholder source="fillMurray" />
<ImagePlaceholder source="fillMurrayGrey" />
<ImagePlaceholder source="fakeImgPlease" />
<ImagePlaceholder source="placeCageCalm" />
<ImagePlaceholder source="placeCageGray" />
<ImagePlaceholder source="placeCageCrazy" />
<ImagePlaceholder source="placeBear" />
<ImagePlaceholder source="placeBearGrey" />
<ImagePlaceholder source="baconMockup" />
<ImagePlaceholder source="placeBeard" />
<ImagePlaceholder source="stevenseGallery" />

Sources List

["https://unsplash.it", "http://via.placeholder.com", "https://placeimg.com", "http://fillmurray.com", "http://fillmurray.com", "http://fakeimg.pl", "http://placecage.com", "https://placebear.com", "http://baconmockup.com", "http://placebeard.it", "http://stevensegallery.com"]

Configuration

You can pass the following props to the ImagePlaceholder component to fine-tune the output.

PropDefaultDescription
sourceunsplashItsource of placeholder images
height320height of rendered image
width320width of rendered image

Development & Contributions

Feature requests/pull requests are welcome. To begin development please fork/clone this repository and run it's development/build enviroment (webpack).

npm install
npm start

The Jest test suite can also be started with npm test or npm test:watch 🔬

To dev-test the component in a testing-project please run npm link on the repository directory and follow below.

npm install -g create-react-app
create-react-app .
npm link react-placeholder-componenet

Licence

Released under The MIT License.

1.1.1

7 years ago

1.1.0

7 years ago

0.1.2

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago

0.0.9

7 years ago

0.0.8

7 years ago

0.0.5

7 years ago

0.0.1

7 years ago