Convert file’s domstring to arraybuffer (bytes) – javascript [duplicate]

  file, image, javascript, typescript

I read image file as ‘File’ object in JavaScript, and then converted it to DomString using –

URL.createObjectURL(File)

Now, I needed to convert this DomString represented Image file back to ArrayBuffer. Is there a method to do this in JavaScript?

Source: Ask Javascript Questions

LEAVE A COMMENT