Socket
Socket
Sign inDemoInstall

react-lazysizes

Package Overview
Dependencies
3
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    react-lazysizes

LazySizes component base on lazysizes plugin.


Version published
Weekly downloads
27
increased by200%
Maintainers
1
Install size
341 kB
Created
Weekly downloads
 

Readme

Source

React LazySizes

LazySizes component for ReactJS base on lazysizes

Installation

NPM

npm install --save react-lazysizes

Bower

bower install --save react-lazysizes

Usage

JS

var LazySizes = require('react-lazysizes');

<LazySizes width='1920' height='1024' dataSrc='http://lorempixel.com/1920/1024/sports/1'/>

UMD

<script src="path/to/react-lazysizes/dist/react-lazysizes.js"></script>
//...
var LazySizes = window.ReactLazysizes;
//...

Example here

Props

NameTypeDefault
srcstring'data:image/gif;base64,R0lGODdhEAAJAIAAAMLCwsLCwiwAAAAAEAAJAAACCoSPqcvtD6OclBUAOw=='
dataSrcstring
dataSizesstring'auto'
dataSrcSet[string, object, array]
classNamestring''
iframeboolfalse

More info see lazysizes api.

Example

View demo or example folder.

Keywords

FAQs

Last updated on 17 Apr 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc