1.0.0 • Published 4 years ago

react-img-input v1.0.0

Weekly downloads
504
License
-
Repository
github
Last release
4 years ago

react-img-input

NPM   License   JavaScript Style Guide   npm downloads   Bundle size   GitHub stars

Another cool React Component Library

🚀 See it in Action

Install

react-img-input

npm install --save react-img-input

Usage

Default Usage

import React from 'react'

import { ReactImgInput } from 'react-img-input'
import 'react-img-input/dist/index.css'

const config = {
  size: 120,
  captureBtn: {
    bg: 'crimson',
    color: '#fff',
  },
  cropBtn: {
    bg: '#F4B230',
    color: '#fff',
  },
  defaultImg: '',
  theme: 'light',
  compression: {
    maxSizeMB: 0.1,
    maxWidthOrHeight: 500,
    useWebWorker: true,
  }
}

const App = () => {
  return <ReactImgInput config={config} setOutput={console.log} />
}
export default App

Support

License

This project is licensed under the MIT License - see the LICENSE file for details