react-lazy-responsive-image
v1.0.0
Published
A React Component to lazy load responsive images
Downloads
37
Maintainers
Readme
React Lazy Responsive Image
A React Component to lazy load responsive images
Example
$ npm install react-lazy-responsive-image --save
import React from 'react';
import ReactDOM from 'react-dom';
import LazyResponsiveImage from 'react-lazy-responsive-image';
ReactDOM.render(
<LazyResponsiveImage
src="[email protected]"
className="test-class"
sources={{
small: '[email protected]',
medium: '[email protected]',
large: '[email protected]|[email protected]',
}}
breakpoints={{
small: 600,
medium: 900,
large: 1200,
}}
/>,
document.getElementById('root')
);