ez-uploader
v0.6.2
Published
This a File Upload Component For Vue 3 - β Built With TypeScript π - β 2 way binding support - β Drag and Drop Support - β File Compress Support Using compressorjs - β Fully Customizable Styling Using Sass Variables ! - β Base 64
Downloads
10
Readme
Ez File Uploader Component For Vue 3
This a File Upload Component For Vue 3
- β Built With TypeScript π
- β 2 way binding support
- β Drag and Drop Support
- β File Compress Support Using compressorjs
- β Fully Customizable Styling Using Sass Variables !
- β Base 64 Support
- β Various File Extentions Preview Icons
Usage
npm i ez-uplpader
yarn add ez-uploader
Single File
<script>
import EzUploader from 'ez-uploader';
import 'ez-uploader/style'
const file = ref(null);
</script>
<template>
<EzUploader v-model="file"></EzUploader>
</template>
Multiple Files
<script>
import EzUploader from 'ez-uploader';
import 'ez-uploader/style'
const file = ref(null);
</script>
<template>
<EzUploader multiple v-model="files"></EzUploader>
</template>
Props
| Name | Desc | Default | Type | | -------------- | -------------------------------------- | ------- | ----------------------- | | base64 | Provide Base 64 for output | false | boolean | | contain | Contain Preview Images | true | boolean | | cover | Cover Preview Images | false | boolean | | deleteBtnClass | class for delete btn | | string | | accept | Set File Accept For the HTML File input | image/* | string (HTML Accept attribute) | | quality | Compress the quality of the uploaded image | 1 | number (0.1 to 1) |
Events
- @validationError {errorMessage, errorType , fileName?}
- @base64Generated (base664 : string | string[])