vue-uploader
VueUploader
VueUploader is a Vue.js component that provides a user-friendly interface for uploading files. It supports both drag-and-drop functionality and traditional file selection.
Features
- Drag-and-Drop Upload: Users can drag files into the drop zone to upload them.
- File Selection: Allows users to click and select files from their file system.
- Multiple File Support: Upload multiple files at once or restrict to a single file.
- File Removal: Option to remove files from the list after they've been added.
Installation
Install VueUploader via npm:
npm install vue-uploader
usage / example
import VueUploader compnent in main.js:
import vueUploader from "vue-uploader";
import "vue-uploader/dist/style.css";
const app = createApp(App);
app.use(vueUploader);
app.mount("#app");
use of the VueUploader
<script setup>
import { ref } from "vue";
const files = ref();
const onFileUpload = (files) => {};
const onRemoveFile = (files) => {};
</script>
<template>
<VueUploader
:multiple="true"
label="Upload or drag & drop"
v-model="files"
></VueUploader>
</template>
Props and events
- @onFileUpload="onFileUpload": This binds the onFileUpload function to the onFileUpload event of the VueUploader component, which will be triggered when a file is uploaded.
- @onRemoveFile="onRemoveFile": This binds the onRemoveFile function to the onRemoveFile event of the VueUploader component, which will be triggered when a file is removed.
- :multiple="false":This prop ensures that only one file can be uploaded at a time.
- label="Upload or drag & drop": This prop sets the label or placeholder text displayed in the uploader component
Preview

Thanks a lot
If you appreciate my work and want to support future projects, consider buying me a coffee! ☕️
Related Packages
@bytescale/upload-widget-vue
Vue File Upload UI Widget — Lightweight & supports: drag and drop, multiple uplo...
107,089
20
@upload-io/vue-uploader
Vue File Upload UI Widget — Lightweight & supports: drag and drop, multiple uplo...
2,924
20
@yazan.alnughnugh/file-upload
File upload component is created to help you upload files using vuejs and ajax
5,055
57
Version History
| Version | Released | License |
|---|---|---|
| 1.1.21 | ||
| 1.1.20 | ||
| 1.1.19 | ||
| 1.1.18 | ||
| 1.1.8 | ||
| 1.1.7 | ||
| 1.1.6 | ||
| 1.1.5 | ||
| 1.1.4 | ||
| 1.1.3 | ||
| 1.1.2 | ||
| 1.1.1 | ||
| 1.1.0 | ||
| 1.0.9 | ||
| 1.0.8 | ||
| 1.0.7 | ||
| 1.0.6 | ||
| 1.0.5 | ||
| 1.0.4 | ||
| 1.0.3 | ||
| 1.0.2 | ||
| 1.0.1 | ||
| 1.0.0 | ||
| 0.0.0 |