0👍
I found a simple fix for this issue when I was looking through the docs, specifically this part that discusses the methods. In the addFile
method, I realized that it passes an event which contains the error if a file is too large. If the file is not too large, the event is null. So I simply do a check, remove the file and return before it gets to the point that it was causing me issues, like so:
addFile (e) {
if (e) {
this.error = e;
this.$refs.filepondUploader.removeFile();
return;
}
const initial = this.$refs.filepondUploader.getFile(0);
const file = initial.getFileEncodeDataURL();
this.$emit('handle-image-upload', file);
}
- [Vuejs]-Webcam not working with JavaScript on some machines
- [Vuejs]-How to make sense of, and then effectively use the console warnings and errors in vue?
Source:stackexchange.com