Created
July 15, 2020 01:43
-
-
Save wildfrontend/32bf2dd4293db5eae4f9592099b44b41 to your computer and use it in GitHub Desktop.
blobToDataURI
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function blobToDataURI(blob, callback) { | |
const reader = new FileReader() | |
reader.readAsDataURL(blob) | |
reader.onload = function (e) { | |
callback(e.target.result) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment