react-placeholder-img
v1.0.0
Published
A react component that renders a placeholder svg image with width and height. Useful for whiteboxing a react application.
Downloads
2
Readme
React Placeholder Image
A simple react component that renders a placeholder image with the specified dimensions.
Useful for Whiteboxing
a React application.
Features
- Renders an svg image with background cross
- Renders the image dimensions
- Supports pixel and percentage based dimensions
Example
Usage
Install the component
npm i react-placeholder-img
Add placeholders to your components
import PlaceHolderImage from 'react-placeholder-img';
export const Home = () => (
<div>
<PlaceHolderImage width="220px" height="160px" />
</div>
);