yagou-upload-file
v1.0.2
Published
>
Downloads
2
Readme
yagou-upload-file
Install
npm install --save yagou-upload-file
Usage
import React, { Component } from 'react'
import UploadFile from '@yagoubi/upload-file'
class Example extends Component {
onError = error => {
console.log(error);
}
onChange = files => {
console.log(files);
}
render () {
return (
<UploadFile
onError={this.onError}
onChange={this.onChange}
/>
)
}
}
props
| props | type | description |
|---|---|---|
| label | string | |
| accepts | array of string | |
| multiple | boolen | |
| maxFiles | number | |
|maxFileSize | number | |
| minFileSize | number | |
| color | string | |
| onError | method | |
| onChange | method | |
License
MIT © yagoubi abdelkader