pqina / vue-filepond

🔌 A handy FilePond adapter component for Vue
https://pqina.nl/filepond
MIT License
1.91k stars 128 forks source link

[Bug] Filepond process cannot read metadata and file size at the same time #263

Open positivedeveloper36 opened 1 year ago

positivedeveloper36 commented 1 year ago

Is there an existing issue for this?

Have you updated Vue FilePond, FilePond, and all plugins?

Describe the bug

My module has add form and edit form. In the edit form, it will show uploaded files

But my problem is each file displays same file size on all files

Reproduction

https://codesandbox.io/s/vue-filepond-live-demo-forked-tt1u1s

The displayed data was fetched from an API and sent using metadata to the filepond process and it worked. But the file size for all files is the same

If I uncomment this script :

     file: {
            name: this.filesFromApi[key].name,
            size: this.filesFromApi[key].size,
     },

It success get the file size correctly. But I can't get the metadata because process of filepond is not being called. You can try the code for make sure

Hope someone helps. Thanks

Environment

- Broser: Firefox, Chrome
- Vue version: Vue version 2.6