Issue
I have downloaded a BLOB which is an image and want to set it as the background of my page. However all the tutorials I have searched show a BLOB as a URL, but mine is something like this (Logged the downloaded object):
Am I missing something or how can I set this to be the background of my page. TIA.
Solution
You can convert this to a blob URL
URL.createObjectURL(Blob)
and then add it to the img
document.querySelector('img').src = URL.createObjectURL(Blob)
Answered By - Nils Schwebel
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.