1.1.2-alpha.0 • Published 6 months ago

react-imgr-development v1.1.2-alpha.0

Weekly downloads
-
License
ISC
Repository
github
Last release
6 months ago

react-imgr

Progressive Image component for React.

TODO

[] remove deprecated lifecycle methods

Installation

// with npm with react-compounds
$ npm install @react-compounds/dropdown  --save

// with yarn with react-compounds
$ yarn add @react-compounds/dropdown

// with npm
$ npm install react-imgr  --save

// with yarn
$ yarn add react-imgr

Usage

This is the basic usage of react-dropdown

import Image from 'react-imgr';

<Image
    src='image.jpg'
    preloadSrc='preloadimage.jpg'
	containerStyle={{
		width: '100%',
		height: 280
	}}
	initialBlur
	alt='alt tag added here'
    scale
    placeholder='placeholder.jpg'
/>

Props

NameTypeRequiredDescription
srcstringtruethe src of image
preloadSrcstringfalsethe src image preload src
containerStyleobjectfalsecontainer css styles
initialBlurbooleantruethe src initial state
altstringtruethe src alt tag
scalebooleanfalsescale the src image
placeholderstringtruethe src of the placeholder image

TODO

  • Production Level
  • CSS Polishing and Transitions
  • Documentation

Run example

$ npm start

License

Apache 2.0