Convert Blob to base64
npm package version
npm downloads
standard JS linter
prettier code formatting
travis ci build status
project license
make a pull request
$ npm install blob-to-base64
# OR
$ yarn add blob-to-base64const blobToBase64 = require('blob-to-base64') const button = document.querySelector('.button') button.addEventListener('click', function (event) { const blob = document.querySelector('.input').files[0] blobToBase64(blob, function (error, base64) { if (!error) { document.querySelector('.result').innerHTML = base64 } }) })
Contributions are welcome!
- Fork it.
- Create your feature branch:
git checkout -b my-new-feature - Commit your changes:
git commit -am 'Add some feature' - Push to the branch:
git push origin my-new-feature - Submit a pull request :D
Or open up a issue.
Licensed under the MIT License.