Is there any way to add user_id to the File received from react-dropzone?

23 Views Asked by At

So I want to add user_id as a property in the file so that I can save the files with specific user_ids. The file is received from the react-dropzone like this with acceptedfiles[0] :

React Dropzone Component

Api call that sends the file to the server: POST Request from Client side

I have tried these two methods which are commented: Tried methods

Route handler: Route Handler

0

There are 0 best solutions below