How to access each specific chunk of a file uploaded by Dropzone.js

63 Views Asked by At

I am using dropzone to upload files to a database, and I want to check the checksum of each chunk in order to see if they are uploading correctly, the problem is I cannot find a way to access a single chunk before it sends it.

I checked the documentation dropzone provides (https://github.com/dropzone/dropzone/blob/main/src/options.js) and i didn't find any call that helps me.

I'm close in believing it can't be done.

I tried the .on('sending',..) but it is triggered only by the file itself and not its chunks.

I want it to happen in the same timeline dropzone uploads so if a chunk is not uploaded correctly to make the try again before going to the next one. So i need to calculate the checksum in the frontend and send it to the back to compare.

0

There are 0 best solutions below