1.0.1 • Published 5 years ago

progressive-image-react v1.0.1

Weekly downloads
2
License
MIT
Repository
-
Last release
5 years ago

progressive-image-react

A react component for lazy-loading images.

Installation

To use this component, you should install it by npm:

npm install progressive-image-react --save-dev

Usage

<ImageLoader className="yourclassname" previewSrc={previewImageSrc} imageSrc={imageSrc} onClick{yourFunc} />

Props description

  • previewSrc*: source of preview image (preview is shown while theactual image is being loaded).
  • imageSrc*: source of actual image
  • onClick: method called on click of the image

Props marked with (*) are required.

License

This software is released under the MIT License.

Acknowledgments

Inspired by progressive-image.js. Thanks and kudos to Craig Bucker.