{"id":13468773,"url":"https://github.com/pqina/vue-filepond","last_synced_at":"2025-04-11T03:29:37.659Z","repository":{"id":37390752,"uuid":"126347767","full_name":"pqina/vue-filepond","owner":"pqina","description":"🔌 A handy FilePond adapter component for Vue","archived":false,"fork":false,"pushed_at":"2023-09-15T12:19:28.000Z","size":4057,"stargazers_count":1972,"open_issues_count":44,"forks_count":124,"subscribers_count":26,"default_branch":"master","last_synced_at":"2025-03-30T22:02:19.782Z","etag":null,"topics":["file","filepond","image-processing","upload","vue"],"latest_commit_sha":null,"homepage":"https://pqina.nl/filepond","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pqina.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null},"funding":{"custom":["https://www.buymeacoffee.com/rikschennink"]}},"created_at":"2018-03-22T14:28:51.000Z","updated_at":"2025-03-27T16:20:49.000Z","dependencies_parsed_at":"2024-01-07T13:01:48.972Z","dependency_job_id":"850fb78a-5edf-4a34-80d4-63473b80c4ba","html_url":"https://github.com/pqina/vue-filepond","commit_stats":{"total_commits":118,"total_committers":18,"mean_commits":6.555555555555555,"dds":"0.43220338983050843","last_synced_commit":"7f5842c4b75777dbcfeb7ae0b4565b2f6a18d06a"},"previous_names":[],"tags_count":31,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pqina%2Fvue-filepond","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pqina%2Fvue-filepond/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pqina%2Fvue-filepond/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pqina%2Fvue-filepond/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pqina","download_url":"https://codeload.github.com/pqina/vue-filepond/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246616684,"owners_count":20806189,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["file","filepond","image-processing","upload","vue"],"created_at":"2024-07-31T15:01:18.835Z","updated_at":"2025-04-03T18:10:05.860Z","avatar_url":"https://github.com/pqina.png","language":"JavaScript","funding_links":["https://www.buymeacoffee.com/rikschennink","https://www.buymeacoffee.com/rikschennink/"],"categories":["JavaScript","UI组件","Components \u0026 Libraries","UI Components [🔝](#readme)","UI Components"],"sub_categories":["形成","UI Components","Form"],"readme":"# Vue FilePond\n\nVue FilePond is a handy adapter component for [FilePond](https://github.com/pqina/filepond), a JavaScript library that can upload anything you throw at it, optimizes images for faster uploads, and offers a great, accessible, silky smooth user experience.\n\n**If you want to use Vue FilePond with Vue 2, please use v6 of this plugin.**\n\n[![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/pqina/vue-filepond/blob/master/LICENSE)\n[![npm version](https://badge.fury.io/js/vue-filepond.svg)](https://www.npmjs.com/package/vue-filepond)\n![npm](https://img.shields.io/npm/dt/vue-filepond)\n\n---\n\n[\u003cimg src=\"https://github.com/pqina/filepond-github-assets/blob/master/header.svg\" alt=\"FilePond\"/\u003e](https://www.buymeacoffee.com/rikschennink/)\n\n[Buy me a Coffee](https://www.buymeacoffee.com/rikschennink/) / [Use FilePond with Pintura](https://pqina.nl/pintura/?ref=github-filepond) / [Dev updates on Twitter](https://twitter.com/rikschennink/)\n\n---\n\n\n### Core Features\n\n- Accepts **directories**, **files**, blobs, local URLs, **remote URLs** and Data URIs.\n- **Drop files**, select on filesystem, **copy and paste files**, or add files using the API.\n- **Async uploading** with AJAX, or encode files as base64 data and send along form post.\n- **Accessible**, tested with AT software like VoiceOver and JAWS, **navigable by Keyboard**.\n- **Image optimization**, automatic image resizing, **cropping**, and **fixes EXIF orientation**.\n- **Responsive**, automatically scales to available space, is functional on both **mobile and desktop devices**.\n\n[Learn more about FilePond](https://pqina.nl/filepond/)\n\n\u003cimg src=\"https://github.com/pqina/filepond-github-assets/blob/master/filepond-animation-01.gif?raw=true\" width=\"370\" alt=\"\"/\u003e\n\n---\n\n### Also need Image Editing?\n\n**Pintura the modern JavaScript Image Editor** is what you're looking for. Pintura supports setting **crop aspect ratios**, **resizing**, **rotating**, **cropping**, and **flipping** images. Above all, it integrates beautifully with FilePond.\n\n[Learn more about Pintura](https://pqina.nl/pintura/?ref=github-vue-filepond)\n\n\u003cimg src=\"https://github.com/pqina/filepond-github-assets/blob/master/filepond_pintura.gif?raw=true\" width=\"600\" alt=\"\"/\u003e\n\n---\n\nInstallation:\n\n**If you're using Vue 2 please run `npm install vue-filepond@^6.0.0`**\n\n```bash\nnpm install vue-filepond filepond\n```\n\nUsage:\n\n```vue\n\u003ctemplate\u003e\n  \u003cdiv id=\"app\"\u003e\n    \u003cfile-pond\n      name=\"test\"\n      ref=\"pond\"\n      label-idle=\"Drop files here...\"\n      v-bind:allow-multiple=\"true\"\n      accepted-file-types=\"image/jpeg, image/png\"\n      server=\"/api\"\n      v-bind:files=\"myFiles\"\n      v-on:init=\"handleFilePondInit\"\n    /\u003e\n  \u003c/div\u003e\n\u003c/template\u003e\n\n\u003cscript\u003e\n// Import Vue FilePond\nimport vueFilePond from \"vue-filepond\";\n\n// Import FilePond styles\nimport \"filepond/dist/filepond.min.css\";\n\n// Import FilePond plugins\n// Please note that you need to install these plugins separately\n\n// Import image preview plugin styles\nimport \"filepond-plugin-image-preview/dist/filepond-plugin-image-preview.min.css\";\n\n// Import image preview and file type validation plugins\nimport FilePondPluginFileValidateType from \"filepond-plugin-file-validate-type\";\nimport FilePondPluginImagePreview from \"filepond-plugin-image-preview\";\n\n// Create component\nconst FilePond = vueFilePond(\n  FilePondPluginFileValidateType,\n  FilePondPluginImagePreview\n);\n\nexport default {\n  name: \"app\",\n  data: function () {\n    return { myFiles: [\"cat.jpeg\"] };\n  },\n  methods: {\n    handleFilePondInit: function () {\n      console.log(\"FilePond has initialized\");\n\n      // FilePond instance methods are available on `this.$refs.pond`\n    },\n  },\n  components: {\n    FilePond,\n  },\n};\n\u003c/script\u003e\n```\n\nWhen using FilePond with an SSR configuration like Nuxt.js it's best to wrap it in `\u003cno-ssr\u003e` tags.\n\n```vue\n\u003ctemplate\u003e\n  \u003cno-ssr\u003e\n    \u003cfile-pond /\u003e\n  \u003c/no-ssr\u003e\n\u003c/template\u003e\n```\n\nUsage in the browser:\n\n```html\n\u003c!DOCTYPE html\u003e\n\u003chtml\u003e\n  \u003chead\u003e\n    \u003ctitle\u003eVue in Browser\u003c/title\u003e\n\n    \u003clink\n      rel=\"stylesheet\"\n      href=\"https://unpkg.com/filepond/dist/filepond.min.css\"\n    /\u003e\n    \u003clink\n      rel=\"stylesheet\"\n      href=\"https://unpkg.com/filepond-plugin-image-preview/dist/filepond-plugin-image-preview.min.css\"\n    /\u003e\n  \u003c/head\u003e\n  \u003cbody\u003e\n    \u003cdiv id=\"app\"\u003e\n      \u003cfile-pond\u003e\u003c/file-pond\u003e\n    \u003c/div\u003e\n\n    \u003cscript src=\"https://unpkg.com/filepond-plugin-image-preview\"\u003e\u003c/script\u003e\n    \u003cscript src=\"https://unpkg.com/filepond\"\u003e\u003c/script\u003e\n    \u003cscript src=\"https://unpkg.com/vue\"\u003e\u003c/script\u003e\n    \u003cscript src=\"https://unpkg.com/vue-filepond@6\"\u003e\u003c/script\u003e\n\n    \u003cscript\u003e\n      new Vue({\n        el: \"#app\",\n        components: {\n          FilePond: vueFilePond.default(FilePondPluginImagePreview),\n        },\n      });\n    \u003c/script\u003e\n  \u003c/body\u003e\n\u003c/html\u003e\n```\n\n[Read the docs for more information](https://pqina.nl/filepond/docs/patterns/frameworks/vue/)\n\n[Live Demo with Code Sandbox](https://codesandbox.io/s/p3v8zoprp7)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpqina%2Fvue-filepond","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpqina%2Fvue-filepond","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpqina%2Fvue-filepond/lists"}