filepond-plugin-file-validate-size
filepond-plugin-file-validate-size copied to clipboard
Support max file size per file type
Hi, thanks for the great plugin.
I want my users to be able to upload images and videos using the same filepond uploader. For images I want a smaller max file size and for videos I want a bigger max file size.
Would it make sense to add this configuration to the plugin? Something like this would fit the use-case perfectly:
const filePondOptions = {
maxFileSize: {
"image/*": 5242880,
"image/png": 10485760,
"video/mp4": 104857600,
},
}
Cheers
I'll consider this. In the meantime, I think it would be fastest to fork the repo and create a custom plugin.
I definitely need this too.. Please consider my PR as there hasn't been any other movement on this in nearly 5 years. 😊
Anyone else in need, unless/until this is merged and released, you can use by adding to your dependencies, thusly:
"filepond-plugin-file-validate-size": "[email protected]:willvincent/filepond-plugin-file-validate-size.git",
Can't load from cdn though, of course.