Is there a way to convert a Blob
into a File
object in ElectronJS? I attempted the following:
return new File([blob], fileName, {lastModified: new Date().getTime(), type: blob.type});
However, it appears that ElectronJs handles the File object differently:
ElectronJs File function:
https://i.stack.imgur.com/fmPmC.png
Chrome Browser File function
https://i.stack.imgur.com/uvNkB.png
I also tried:
(blob as any).name = fileName;
(blob as any).lastModified = new Date().getTime();
return blob as File;
Unfortunately, this approach did not yield the desired result.