{"_id":"blob-util","_rev":"20-c57db182488c0210fde9e86c432e84b2","name":"blob-util","description":"Utilities for working with Blob objects in the browser","dist-tags":{"latest":"2.0.2"},"versions":{"1.0.0":{"name":"blob-util","version":"1.0.0","description":"Utilities for working with Blob objects in the browser","main":"lib/index.js","repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"keywords":["blob","blobs","binary","util","utils"],"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"license":"Apache","bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"scripts":{"test-node":"echo 'node tests disabled'","test-browser":"./bin/test-browser.js","jshint":"jshint -c .jshintrc *.js test/test.js","test":"npm run jshint && ./bin/run-test.sh","build":"mkdir -p dist && browserify lib/index.js -s blobUtil -o dist/blob-util.js && npm run min","min":"uglifyjs dist/blob-util.js -mc > dist/blob-util.min.js","dev":"browserify test/test.js > test/test-bundle.js && npm run dev-server","dev-server":"./bin/dev-server.js","coverage":"npm test --coverage && istanbul check-coverage --lines 100 --function 100 --statements 100 --branches 100","jsdoc2md":"jsdoc2md --heading-depth 3 ./lib/index.js > api.md","jsdoc":"jsdoc -d doc ./lib/index.js"},"dependencies":{"blob":"0.0.4","es3ify":"^0.1.3","jsdoc":"^3.3.0-alpha10","lie":"^2.6.0"},"devDependencies":{"bluebird":"^1.0.7","browserify":"~2.36.0","chai":"~1.8.1","chai-as-promised":"~4.1.0","http-server":"~0.5.5","istanbul":"^0.2.7","jsdoc":"^3.3.0-alpha10","jsdoc-to-markdown":"^0.5.9","jshint":"~2.3.0","mocha":"~1.18","phantomjs":"^1.9.7-5","request":"^2.36.0","sauce-connect-launcher":"^0.4.2","uglify-js":"^2.4.13","watchify":"~0.4.1","wd":"^0.2.21"},"browserify":{"transform":["es3ify"]},"gitHead":"a3007ec78bc16d9f0ad85feff423fc070befa749","homepage":"https://github.com/nolanlawson/blob-util","_id":"blob-util@1.0.0","_shasum":"9cbfd2eedeacf68f767cb914d810a0a3ff9c5a6e","_from":".","_npmVersion":"1.4.13","_npmUser":{"name":"nolanlawson","email":"nolan@nolanlawson.com"},"maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"dist":{"shasum":"9cbfd2eedeacf68f767cb914d810a0a3ff9c5a6e","tarball":"https://registry.npmjs.org/blob-util/-/blob-util-1.0.0.tgz","integrity":"sha512-qwjWPa1/P6l6F7D27acV6RX657k4PQ7ifNjOCY0MXEkgqzIm6UVO17BXxCoso542UUQGZrjZr5uCtqsIphpd6g==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCzgVyrgLM/uQHccm+YgwNBF6Pu/qrfp3U4v64UIgT9jQIhAIYXGyekGSInKEehYwHyvZ+UGBkHSDbDANPmY09OMnq0"}]},"directories":{}},"1.1.0":{"name":"blob-util","version":"1.1.0","description":"Utilities for working with Blob objects in the browser","main":"lib/index.js","repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"keywords":["blob","blobs","binary","util","utils"],"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"license":"Apache","bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"scripts":{"test-node":"echo 'node tests disabled'","test-browser":"./bin/test-browser.js","jshint":"jshint -c .jshintrc lib/*.js test/test.js","test":"npm run jshint && ./bin/run-test.sh","build":"mkdir -p dist && browserify lib/index.js -s blobUtil -o dist/blob-util.js && npm run min","min":"uglifyjs dist/blob-util.js -mc > dist/blob-util.min.js","dev":"browserify test/test.js > test/test-bundle.js && npm run dev-server","dev-server":"./bin/dev-server.js","coverage":"npm test --coverage && istanbul check-coverage --lines 100 --function 100 --statements 100 --branches 100","jsdoc2md":"jsdoc2md --heading-depth 3 ./lib/index.js > api.md","jsdoc":"jsdoc -d doc ./lib/index.js"},"dependencies":{"blob":"0.0.4","es3ify":"^0.1.3","jsdoc":"^3.3.0-alpha10","lie":"^2.6.0"},"devDependencies":{"bluebird":"^1.0.7","browserify":"~2.36.0","chai":"~1.8.1","chai-as-promised":"~4.1.0","http-server":"~0.5.5","istanbul":"^0.2.7","jsdoc":"^3.3.0-alpha10","jsdoc-to-markdown":"^0.5.9","jshint":"~2.3.0","mocha":"~1.18","phantomjs":"^1.9.7-5","request":"^2.36.0","sauce-connect-launcher":"^0.4.2","uglify-js":"^2.4.13","watchify":"~0.4.1","wd":"^0.2.21"},"browserify":{"transform":["es3ify"]},"gitHead":"8fb8b0e3bad83175206ac7b1f3010b8e0944e629","homepage":"https://github.com/nolanlawson/blob-util","_id":"blob-util@1.1.0","_shasum":"5f646e812844a79a985047ccd0eb4fdca8731f64","_from":".","_npmVersion":"2.0.0-alpha-5","_npmUser":{"name":"nolanlawson","email":"nolan@nolanlawson.com"},"maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"dist":{"shasum":"5f646e812844a79a985047ccd0eb4fdca8731f64","tarball":"https://registry.npmjs.org/blob-util/-/blob-util-1.1.0.tgz","integrity":"sha512-d9GzoYeiHz9GDdahmBrZKDwQ7B1BPnOWumHWa6CNgYAZfBw4tcD6FNgrCMknwwVqyz1vLN37ZJvFVFzosEYL/g==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCIfeQ6Fb67PIDl9ViaqLhCbsrAp3Im7Z72B34TImKJsgIgZwPm32mIRcKe57ZZaO2lU941ITaykrigT8hUHRrYWjY="}]},"directories":{}},"1.1.1":{"name":"blob-util","version":"1.1.1","description":"Utilities for working with Blob objects in the browser","main":"lib/index.js","repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"keywords":["blob","blobs","binary","util","utils"],"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"license":"Apache","bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"scripts":{"test-node":"echo 'node tests disabled'","test-browser":"./bin/test-browser.js","jshint":"jshint -c .jshintrc lib/*.js test/test.js","test":"npm run jshint && ./bin/run-test.sh","build":"mkdir -p dist && browserify lib/index.js -s blobUtil -o dist/blob-util.js && npm run min","min":"uglifyjs dist/blob-util.js -mc > dist/blob-util.min.js","dev":"browserify test/test.js > test/test-bundle.js && npm run dev-server","dev-server":"./bin/dev-server.js","coverage":"npm test --coverage && istanbul check-coverage --lines 100 --function 100 --statements 100 --branches 100","jsdoc2md":"jsdoc2md --heading-depth 3 ./lib/index.js > api.md","jsdoc":"jsdoc -d doc ./lib/index.js"},"dependencies":{"blob":"0.0.4","es3ify":"^0.1.3","jsdoc":"^3.3.0-alpha10","lie":"^2.6.0"},"devDependencies":{"bluebird":"^1.0.7","browserify":"~2.36.0","chai":"~1.8.1","chai-as-promised":"~4.1.0","http-server":"~0.5.5","istanbul":"^0.2.7","jsdoc":"^3.3.0-alpha10","jsdoc-to-markdown":"^0.5.9","jshint":"~2.3.0","mocha":"~1.18","phantomjs":"^1.9.7-5","request":"^2.36.0","sauce-connect-launcher":"^0.4.2","uglify-js":"^2.4.13","watchify":"~0.4.1","wd":"^0.2.21"},"browserify":{"transform":["es3ify"]},"gitHead":"9f8682dd6eb6e9b9328e0664c4afe335bca199a5","homepage":"https://github.com/nolanlawson/blob-util","_id":"blob-util@1.1.1","_shasum":"f579a34ff05fea7aefd64642b5111eca05557805","_from":".","_npmVersion":"1.4.13","_npmUser":{"name":"nolanlawson","email":"nolan@nolanlawson.com"},"maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"dist":{"shasum":"f579a34ff05fea7aefd64642b5111eca05557805","tarball":"https://registry.npmjs.org/blob-util/-/blob-util-1.1.1.tgz","integrity":"sha512-Fz5MVjZNfscYgQsQcOCqBEUj7/YTAtxScs0amidhL05w5ZxSrR/1RdZj9tdromm5PNgt1ME1C9FUXMeWRnyqRg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIE2a/5UlY5kPwA3o12Mn+YHV/Cxca9Q7SpQPoHf/nlUwAiEA6IPxmEvEBfC1ymt1AVX+fxW6c/C1ntJkISSExxpqERg="}]},"directories":{}},"1.1.2":{"name":"blob-util","version":"1.1.2","description":"Utilities for working with Blob objects in the browser","main":"lib/index.js","repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"keywords":["blob","blobs","binary","util","utils"],"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"license":"Apache","bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"scripts":{"test-node":"echo 'node tests disabled'","test-browser":"./bin/test-browser.js","jshint":"jshint -c .jshintrc lib/*.js test/test.js","test":"npm run jshint && ./bin/run-test.sh","build":"mkdirp dist && npm run browserify && npm run min","browserify":"browserify . -p bundle-collapser/plugin -s blobUtil | ./bin/es3ify.js | derequire > dist/blob-util.js","min":"uglifyjs dist/blob-util.js -mc > dist/blob-util.min.js","dev":"browserify test/test.js > test/test-bundle.js && npm run dev-server","dev-server":"./bin/dev-server.js","coverage":"npm test --coverage && istanbul check-coverage --lines 100 --function 100 --statements 100 --branches 100","jsdoc2md":"jsdoc2md --heading-depth 3 ./lib/index.js > api.md","jsdoc":"jsdoc -d doc ./lib/index.js"},"dependencies":{"blob":"0.0.4","pouchdb-promise":"0.0.0"},"devDependencies":{"bluebird":"^1.0.7","browserify":"^9.0.3","bundle-collapser":"^1.1.4","chai":"~1.8.1","chai-as-promised":"~4.1.0","derequire":"^2.0.0","es3ify":"^0.1.3","http-server":"~0.5.5","istanbul":"^0.2.7","jsdoc":"^3.3.0-alpha10","jsdoc-to-markdown":"^0.5.9","jshint":"~2.3.0","mkdirp":"^0.5.0","mocha":"~1.18","phantomjs":"^1.9.7-5","request":"^2.36.0","sauce-connect-launcher":"^0.4.2","selenium-standalone":"3.0.2","uglify-js":"^2.4.13","watchify":"^2.4.0","wd":"^0.2.21"},"gitHead":"6cdd3af6d7599cc7d29ad476eb4018e495d084e8","homepage":"https://github.com/nolanlawson/blob-util","_id":"blob-util@1.1.2","_shasum":"6402fb11b7801005f1c00d6094a00db1e832fee3","_from":".","_npmVersion":"2.7.0","_nodeVersion":"0.10.36","_npmUser":{"name":"nolanlawson","email":"nolan@nolanlawson.com"},"maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"dist":{"shasum":"6402fb11b7801005f1c00d6094a00db1e832fee3","tarball":"https://registry.npmjs.org/blob-util/-/blob-util-1.1.2.tgz","integrity":"sha512-fU/cGKvM/GGWh7wBufgSu8i4FctLtjgYiXuSi5Q91sK3QQi0kCrWoRzu6L0tTvqkWcJwU8mmDXE8W7/8eMsK4w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBTHuDweVb9UaG3NI4PItcD+LwnNlqN/qfEaCpbcLRQmAiA9s6bHdHNOCgOtQ5mZj9O3siq4fGKppuqjoC6fnCs+XQ=="}]},"directories":{}},"1.2.0":{"name":"blob-util","version":"1.2.0","description":"Utilities for working with Blob objects in the browser","main":"lib/index.js","repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"keywords":["blob","blobs","binary","util","utils"],"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"license":"Apache-2.0","bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"scripts":{"test-node":"echo 'node tests disabled'","test-browser":"./bin/test-browser.js","jshint":"jshint -c .jshintrc lib/*.js test/test.js","test":"npm run jshint && ./bin/run-test.sh","build":"mkdirp dist && npm run browserify && npm run min","browserify":"browserify . -p bundle-collapser/plugin -s blobUtil | ./bin/es3ify.js | derequire > dist/blob-util.js","min":"uglifyjs dist/blob-util.js -mc > dist/blob-util.min.js","dev":"browserify test/test.js > test/test-bundle.js && npm run dev-server","dev-server":"./bin/dev-server.js","coverage":"npm test --coverage && istanbul check-coverage --lines 100 --function 100 --statements 100 --branches 100","jsdoc2md":"jsdoc2md --heading-depth 3 ./lib/index.js > api.md","jsdoc":"jsdoc -d doc ./lib/index.js"},"dependencies":{"blob":"0.0.4","pouchdb-promise":"0.0.0"},"devDependencies":{"bluebird":"^1.0.7","browserify":"^9.0.3","bundle-collapser":"^1.1.4","chai":"~1.8.1","chai-as-promised":"~4.1.0","derequire":"^2.0.0","es3ify":"^0.1.3","http-server":"~0.5.5","istanbul":"^0.2.7","jsdoc":"^3.3.0-alpha10","jsdoc-to-markdown":"^0.5.9","jshint":"~2.3.0","mkdirp":"^0.5.0","mocha":"~1.18","phantomjs":"^1.9.7-5","request":"^2.36.0","sauce-connect-launcher":"^0.4.2","selenium-standalone":"3.0.2","uglify-js":"^2.4.13","watchify":"^2.4.0","wd":"^0.2.21"},"gitHead":"9f3a4f926eb2a09a046f0f7db65d47b9824b1c0e","homepage":"https://github.com/nolanlawson/blob-util#readme","_id":"blob-util@1.2.0","_shasum":"99e24deb1090caaeb87757deacc74354d9f2ad6b","_from":".","_npmVersion":"3.3.12","_nodeVersion":"5.3.0","_npmUser":{"name":"nolanlawson","email":"nolan@nolanlawson.com"},"maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"dist":{"shasum":"99e24deb1090caaeb87757deacc74354d9f2ad6b","tarball":"https://registry.npmjs.org/blob-util/-/blob-util-1.2.0.tgz","integrity":"sha512-ZxPLvC/5F3rsWu668cSmlin9VHiUIo+Cgte//dGLuPLcd2JtFu37L7yZ0ZNAnVjfWvH95AhJwu0WFNfYSLMaJw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCp0MAnUKMsgjBs+UP/t3tUBkO/rNtRRI20LEUCcliL7AIgDM0Cj+2PGjmWIw0z1zWWPTtJ9p7/pdgNOsvsr4DcnnY="}]},"directories":{}},"1.2.1":{"name":"blob-util","version":"1.2.1","description":"Utilities for working with Blob objects in the browser","main":"lib/index.js","repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"keywords":["blob","blobs","binary","util","utils"],"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"license":"Apache-2.0","bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"scripts":{"jshint":"jshint -c .jshintrc lib/*.js test/test.js","test":"npm run jshint && zuul ./test/test.js","test-local":"zuul ./test/test.js --local 9000","test-phantom":"zuul ./test/test.js --phantom","build":"mkdirp dist && npm run browserify && npm run min","browserify":"browserify . -p bundle-collapser/plugin -s blobUtil | ./bin/es3ify.js | derequire > dist/blob-util.js","min":"uglifyjs dist/blob-util.js -mc > dist/blob-util.min.js","jsdoc2md":"jsdoc2md --heading-depth 3 ./lib/index.js > api.md","jsdoc":"jsdoc -d doc ./lib/index.js"},"dependencies":{"blob":"0.0.4","native-or-lie":"1.0.0"},"devDependencies":{"browserify":"^9.0.3","bundle-collapser":"^1.1.4","chai":"~1.8.1","chai-as-promised":"~4.1.0","derequire":"^2.0.0","es3ify":"^0.1.3","istanbul":"^0.2.7","jsdoc":"^3.3.0-alpha10","jsdoc-to-markdown":"^0.5.9","jshint":"~2.3.0","mkdirp":"^0.5.0","mocha":"~1.18","phantomjs":"^1.9.7-5","phantomjs-polyfill":"0.0.1","request":"^2.36.0","uglify-js":"^2.4.13","zuul":"^3.10.1"},"files":["lib","dist"],"gitHead":"aefa065d71d642ad24bf0c5996e1a80bb720719e","homepage":"https://github.com/nolanlawson/blob-util#readme","_id":"blob-util@1.2.1","_shasum":"cda95814d2359802611a6110fe0bc88aa2dcaa2f","_from":".","_npmVersion":"3.5.3","_nodeVersion":"5.3.0","_npmUser":{"name":"nolanlawson","email":"nolan@nolanlawson.com"},"dist":{"shasum":"cda95814d2359802611a6110fe0bc88aa2dcaa2f","tarball":"https://registry.npmjs.org/blob-util/-/blob-util-1.2.1.tgz","integrity":"sha512-+MrSYpmGt/ebpR2lRuxZPCPzTDzNpv01zi+zY4N/7AVHqc+LpRvJ8DTCJQffJVnJVnSKwmOhx0wTcC4bOtJyRQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD+W/qQoBZQvfbyw7zpKxvgjjAUuBOmtXNav2nKQkXGwwIgdX3ItA35upYiXdFK6XdXAwepdgXoK0edGt5tkqXXQdU="}]},"maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"_npmOperationalInternal":{"host":"packages-13-west.internal.npmjs.com","tmp":"tmp/blob-util-1.2.1.tgz_1457495874876_0.12545699439942837"},"directories":{}},"1.3.0":{"name":"blob-util","version":"1.3.0","description":"Utilities for working with Blob objects in the browser","main":"lib/index.js","repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"keywords":["blob","blobs","binary","util","utils"],"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"license":"Apache-2.0","bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"scripts":{"jshint":"jshint -c .jshintrc lib/*.js test/test.js","test":"npm run jshint && zuul ./test/test.js","test-local":"zuul ./test/test.js --local 9000","build":"mkdirp dist && npm run browserify && npm run min","browserify":"browserify . -p bundle-collapser/plugin -s blobUtil | ./bin/es3ify.js | derequire > dist/blob-util.js","min":"uglifyjs dist/blob-util.js -mc > dist/blob-util.min.js","jsdoc2md":"jsdoc2md --heading-depth 3 ./lib/index.js > README.md","jsdoc":"jsdoc -d docs ./lib/index.js && mv -f docs/global.html docs/index.html"},"dependencies":{"blob":"0.0.4","native-or-lie":"1.0.2"},"devDependencies":{"browserify":"^9.0.3","bundle-collapser":"^1.1.4","chai":"~1.8.1","chai-as-promised":"~4.1.0","derequire":"^2.0.0","es3ify":"^0.1.3","istanbul":"^0.2.7","jsdoc":"^3.3.0-alpha10","jsdoc-to-markdown":"^0.5.9","jshint":"~2.3.0","mkdirp":"^0.5.0","mocha":"~1.18","request":"^2.36.0","uglify-js":"^2.4.13","zuul":"^3.10.1","zuul-ngrok":"github:nolanlawson/zuul-ngrok#patch-1"},"files":["lib","dist"],"gitHead":"f3cb2a847d35a5554fb2f24fe189ab1fefc4417f","homepage":"https://github.com/nolanlawson/blob-util#readme","_id":"blob-util@1.3.0","_npmVersion":"5.3.0","_nodeVersion":"8.2.1","_npmUser":{"name":"nolanlawson","email":"nolan@nolanlawson.com"},"dist":{"integrity":"sha512-cjmYgWj8BQwoX+95rKkWvITL6PiEhSr19sX8qLRu+O6J2qmWmgUvxqhqJn425RFAwLovdDNnsCQ64RRHXjsXSg==","shasum":"dbb4e8caffd50b5720d347e1169b6369ba34fe95","tarball":"https://registry.npmjs.org/blob-util/-/blob-util-1.3.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDlqJX3XQ3ZK7qGK13MmWZeBERCkjkPJ95pLqhR60mWTQIgL2QlKmHIMBAK95ryzZaNbn8S6z2T57fftHw+ExROgUE="}]},"maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/blob-util-1.3.0.tgz_1502225923385_0.7276130490936339"},"directories":{}},"2.0.0":{"name":"blob-util","version":"2.0.0","description":"Utilities for working with Blob objects in the browser","main":"dist/blob-util.cjs.js","module":"dist/blob-util.es.js","types":"dist/blob-util.d.ts","repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"keywords":["blob","blobs","binary","util","utils"],"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"license":"Apache-2.0","bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"scripts":{"lint":"standard test/*js bin/*js && tslint src/*ts","test":"npm run build && npm run lint && zuul --no-coverage ./test/test.js","test-local":"npm run build && zuul ./test/test.js --local 9000 --no-coverage","clean":"rimraf dist lib && mkdirp dist lib","build":"run-s clean build-ts build-js min","build-ts":"tsc src/blob-util.ts --target ES6 --module es2015 --outDir lib -d && cpy lib/blob-util.d.ts dist/","build-js":"run-p build-es build-cjs build-umd && rimraf lib","build-es":"rollup -i lib/blob-util.js -f es -o dist/blob-util.es.js","build-cjs":"rollup -i lib/blob-util.js -f cjs -o dist/blob-util.cjs.js","build-umd":"rollup -i lib/blob-util.js -f umd -n blobUtil -o dist/blob-util.js","min":"uglifyjs dist/blob-util.js -mc > dist/blob-util.min.js","doc":"run-s cleanup-doc gen-doc gen-readme cleanup-doc","gen-doc":"typedoc --out docs-tmp --target ES6 --theme markdown --mdHideSources --excludePrivate --exclude private.ts src","gen-readme":"node bin/write-docs-to-readme.js","cleanup-doc":"rimraf docs-tmp"},"devDependencies":{"bundle-collapser":"^1.1.4","chai":"~1.8.1","chai-as-promised":"~4.1.0","cpy-cli":"^1.0.1","istanbul":"^0.2.7","mkdirp":"^0.5.0","mocha":"~1.18","native-or-lie":"1.0.2","npm-run-all":"^4.1.3","pify":"^3.0.0","request":"^2.36.0","rimraf":"^2.6.2","rollup":"^0.59.1","standard":"^11.0.1","tslint":"^5.10.0","tslint-config-standard":"^7.0.0","typedoc":"^0.11.1","typedoc-plugin-markdown":"^1.1.11","typescript":"^2.8.3","uglify-js":"^2.4.13","zuul":"^3.10.1","zuul-ngrok":"github:nolanlawson/zuul-ngrok#patch-1"},"files":["dist"],"gitHead":"a78038a09133116df73a7d67dd4835e81f97a2fa","homepage":"https://github.com/nolanlawson/blob-util#readme","_id":"blob-util@2.0.0","_npmVersion":"5.10.0","_nodeVersion":"9.11.1","_npmUser":{"name":"nolanlawson","email":"nolan@nolanlawson.com"},"dist":{"integrity":"sha512-TEBqe2b2hf6vH8T/zCVTGgSgyEUcmPIvVtRO6VM0njruehIeC4vGaQ3rj2boXvetda/MBTuowLMVd+r+QLPyew==","shasum":"2e43c6309b0f8c6e857bc4226330c1911e96a45e","tarball":"https://registry.npmjs.org/blob-util/-/blob-util-2.0.0.tgz","fileCount":7,"unpackedSize":62699,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbAzhyCRA9TVsSAnZWagAAM7kQAKH/5ItllQmB7uv7VmFo\n2BWAopJa8RqKDOBey9Ngwv/zR8tPUKLl40mdUoIKNwtkOxoJIu8KewDXiHHo\nKKhDHkYVPVhUNn/WlL9hAOertAe1CY+4pNVynyKMlP6n7dt5DLLoB8U1ljwC\n3P4kGrdWcBAFLyAWHALT5ocI8LJicd/5K4JUngEDKuiMuYr0GKIMYQZsFtcN\nnGObw6XpSLMXBfVPvvnHRufNv1zPbl6Qwae6Hyrfp+FFfkdqcsB+/xZvJNhz\n8lFdMYWwL+UhxOajDO0wTe2SN5Lstw+ErnlFsoorWcx8Rp7w0T3zPWSzKqXP\ne+hdhwig3JCLO0s7gGAw0XkUDiS9WdcqpnW7s1afOdlP3y82espOe4SinLTX\nzH4qYJY/LBuc6e6eaHVjTxcOeVzAXfGWPAH396FnFzfhJsGL3AtVYklMg80a\nI6EpkSqrsz5qwN9aWbGlJ7ipa+9/dhgAtAAYM8R1M9L38v02FIFfmVrpdxzG\nSQ80PLza0OkXvM6HwSH1aaX7dlwXsOtYrldY4H/BWcZtQWo6ewiXyVobhjUW\nks/3HTO7mNp0KIhgZ/ZMbbGZs4qjrZMXFoFGaJmP77VivBS0SzqZjt7Hgyjf\nxUIi4Dp1sgLsxt8ewS6Vx818TtQxS2MYgaH+JU0GneFxI0KXpeB/ot+56mEk\nxPV6\r\n=IAxg\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAIM2l4JodYVafWDsxIRN296ksP+VBPzvN3F/QrqPGJqAiEAkErI1CjGOEAyc7qo4fFQxEE/1RBLYDDagzeMhjQdfnc="}]},"maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/blob-util_2.0.0_1526937713361_0.9299398606255334"},"_hasShrinkwrap":false},"2.0.1":{"name":"blob-util","version":"2.0.1","description":"Utilities for working with Blob objects in the browser","main":"dist/blob-util.cjs.js","module":"dist/blob-util.es.js","types":"dist/blob-util.d.ts","repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"keywords":["blob","blobs","binary","util","utils"],"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"license":"Apache-2.0","bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"scripts":{"lint":"standard test/*js bin/*js && tslint src/*ts","test":"npm run build && npm run lint && zuul --no-coverage ./test/test.js","test-local":"npm run build && zuul ./test/test.js --local 9000 --no-coverage","clean":"rimraf dist lib && mkdirp dist lib","prepublish":"npm run build","build":"run-s clean build-ts build-js min","build-ts":"tsc src/blob-util.ts --target ES6 --module es2015 --outDir lib -d && cpy lib/blob-util.d.ts dist/","build-js":"run-p build-es build-cjs build-umd && rimraf lib","build-es":"rollup -i lib/blob-util.js -f es -o dist/blob-util.es.js","build-cjs":"rollup -i lib/blob-util.js -f cjs -o dist/blob-util.cjs.js","build-umd":"rollup -i lib/blob-util.js -f umd -n blobUtil -o dist/blob-util.js","min":"uglifyjs dist/blob-util.js -mc > dist/blob-util.min.js","doc":"run-s cleanup-doc gen-doc gen-readme cleanup-doc","gen-doc":"typedoc --out docs-tmp --target ES6 --theme markdown --mdHideSources --excludePrivate --exclude private.ts src","gen-readme":"node bin/write-docs-to-readme.js","cleanup-doc":"rimraf docs-tmp"},"devDependencies":{"bundle-collapser":"^1.1.4","chai":"~1.8.1","chai-as-promised":"~4.1.0","cpy-cli":"^1.0.1","istanbul":"^0.2.7","mkdirp":"^0.5.0","mocha":"~1.18","native-or-lie":"1.0.2","npm-run-all":"^4.1.3","pify":"^3.0.0","request":"^2.36.0","rimraf":"^2.6.2","rollup":"^0.59.1","standard":"^11.0.1","tslint":"^5.10.0","tslint-config-standard":"^7.0.0","typedoc":"^0.11.1","typedoc-plugin-markdown":"^1.1.11","typescript":"^2.8.3","uglify-js":"^2.4.13","zuul":"^3.10.1","zuul-ngrok":"github:nolanlawson/zuul-ngrok#patch-1"},"files":["dist"],"gitHead":"43b02c5f17d002b437cb9522922044911537f5fb","homepage":"https://github.com/nolanlawson/blob-util#readme","_id":"blob-util@2.0.1","_npmVersion":"5.10.0","_nodeVersion":"9.11.1","_npmUser":{"name":"nolanlawson","email":"nolan@nolanlawson.com"},"dist":{"integrity":"sha512-9feHu3VfxLQapt/Z3A6Erx/fGzM0GpYmLdykJvkn0FsDjq8Xwne9VM/8oGL8NpsqW4YYciEx2cpMro3UmuKkJg==","shasum":"2d3f2ce28f3afbd5831b9275416555f153751911","tarball":"https://registry.npmjs.org/blob-util/-/blob-util-2.0.1.tgz","fileCount":9,"unpackedSize":80619,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbAzjXCRA9TVsSAnZWagAAWkwP/R/rba0igr0vPaTOkmIT\nUpbSqQAkUWm8mlpQ8E8athMGkfpa4fAhDRPDw/W1s+tghiGFgXGO7ygVUlue\nDMHE/dZRU7ezXM7YsQZz2ZPjKUyCqplXVXl84JUFcygCWDIbceELEpPpI7P1\npri1RjluWSBny5GUPKSTrhpH6FWxnZF5vYgTtEWnHaGpnbTSMhLAzPFlbDBV\nj7gXpjU9yvy1EzsdWvJhIBMX6zutat5IbpAcY7lIL6N/oxy0OHu+cW4QqnxL\n4rb/dtH/L1yJFZxNcgrRH61w4p7AiNkEPo/g2Uf3HGwxIhLcAawL+v/ngXw+\nBisx/8FLaz4Xx0y2akC1RNyQWpc39nQyK6uxKS/PHjv+68OBaKi8FA/oo5Xh\nPJmxaiOmc671jiwzm/FLpcRwQuDZkIDQjkuJTrAD6dnBKswof6kye2TKL2Qh\nBftZQLsESYNqbc2W1SEZ6iuNeU7IkHPtU8QgyXDdOeIRQrZcdmmBVOftXVq1\nhAODCuNBDtJXsVEKypAQ/ST7DZsdgROQrt7Quxbs5+9uPxhX4mguo8rXWonN\nhd2IVGmn/480V79CeYK/WbiuO+G65TtLsiE5onUREZeHXfDAbfMt/GiVfzv9\niHK97VzU806ynkdNRcdt4ty6ejhrAFTOut87CQZZPBAE0PkgEgwKVGJlaEnu\npVCU\r\n=gmN1\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDkWcoyqmtcCM/u9ipIeB4IG7T/GvjQrTBGh6t+ksOWLwIhAJakvSy7/AhOb7Q1Pv/FDK5xs5gaqFUze2zXjiUFWlw6"}]},"maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/blob-util_2.0.1_1526937814135_0.785704978803897"},"_hasShrinkwrap":false},"2.0.2":{"name":"blob-util","version":"2.0.2","description":"Utilities for working with Blob objects in the browser","main":"dist/blob-util.cjs.js","module":"dist/blob-util.es.js","types":"dist/blob-util.d.ts","repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"keywords":["blob","blobs","binary","util","utils"],"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"license":"Apache-2.0","bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"scripts":{"lint":"standard test/*js bin/*js && tslint src/*ts","test":"npm run build && npm run lint && zuul --no-coverage ./test/test.js","test-local":"npm run build && zuul ./test/test.js --local 9000 --no-coverage","clean":"rimraf dist lib && mkdirp dist lib","prepublish":"npm run build","build":"run-s clean build-ts build-js min","build-ts":"tsc src/blob-util.ts --target ES6 --module es2015 --outDir lib -d && cpy lib/blob-util.d.ts dist/","build-js":"run-p build-es build-cjs build-umd && rimraf lib","build-es":"rollup -i lib/blob-util.js -f es -o dist/blob-util.es.js","build-cjs":"rollup -i lib/blob-util.js -f cjs -o dist/blob-util.cjs.js","build-umd":"rollup -i lib/blob-util.js -f umd -n blobUtil -o dist/blob-util.js","min":"uglifyjs dist/blob-util.js -mc > dist/blob-util.min.js","doc":"run-s cleanup-doc gen-doc gen-readme cleanup-doc","gen-doc":"typedoc --out docs-tmp --target ES6 --theme markdown --mdHideSources --excludePrivate --exclude private.ts src","gen-readme":"node bin/write-docs-to-readme.js","cleanup-doc":"rimraf docs-tmp"},"devDependencies":{"bundle-collapser":"^1.1.4","chai":"~1.8.1","chai-as-promised":"~4.1.0","cpy-cli":"^1.0.1","istanbul":"^0.2.7","mkdirp":"^0.5.0","mocha":"~1.18","native-or-lie":"1.0.2","npm-run-all":"^4.1.3","pify":"^3.0.0","request":"^2.36.0","rimraf":"^2.6.2","rollup":"^0.59.1","standard":"^11.0.1","tslint":"^5.10.0","tslint-config-standard":"^7.0.0","typedoc":"^0.11.1","typedoc-plugin-markdown":"^1.1.11","typescript":"^2.8.3","uglify-js":"^2.4.13","zuul":"^3.10.1","zuul-ngrok":"github:nolanlawson/zuul-ngrok#patch-1"},"files":["dist"],"gitHead":"fbe16e845b1a7a7fafb842f371ce7d5a802c5faf","homepage":"https://github.com/nolanlawson/blob-util#readme","_id":"blob-util@2.0.2","_npmVersion":"5.10.0","_nodeVersion":"9.11.1","_npmUser":{"name":"nolanlawson","email":"nolan@nolanlawson.com"},"dist":{"integrity":"sha512-T7JQa+zsXXEa6/8ZhHcQEW1UFfVM49Ts65uBkFL6fz2QmrElqmbajIDJvuA0tEhRe5eIjpV9ZF+0RfZR9voJFQ==","shasum":"3b4e3c281111bb7f11128518006cdc60b403a1eb","tarball":"https://registry.npmjs.org/blob-util/-/blob-util-2.0.2.tgz","fileCount":9,"unpackedSize":79030,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbA0moCRA9TVsSAnZWagAATg4QAINg3ITVilsFlvqL4a5d\nfE25vFpdAgreT1O2POzKcZmQ09inK9aIyxKjzhpTmOAXgd/42SrB8ILGuEjN\nIV4Icote9V3Z2E5tPgOmX5X/3T0FBmym9/Lkc4XUz5EsIx1Ojc4iAHUPYghD\nzz/lUwf/knrJkKKCik36Z6g56PzcESq+xPG42/U/IOAk2CtA5ZPDHBtdIbI4\nyj6FhognqvrkWzJHevgYUoBFzef4yWGIFi/Vzp/QFhPCYyy9e/NikAxU35kP\nPVPou3ld6GOBy/HDbn1Ole2vGXtny53mQdsx49TCcm7lUt1wKJbm5RCkX9RT\nnaMrhpIR8CMJqqaqSj6gcIpQPhoz2nsdn0DfAlgDUs8/1MvVKtg+KA1tXY00\nyUTrRkf15PWfO9YOTDUKC8XUknXC6D5+akLRVLsg3Z2yHeHvoQHVHmKR/dG3\n4e/5Q7sJ6gD8gh5BCpcW9vNsSZnwecFRwb7+fo6Xa4ZoZcvlr7R7dxrOj70V\n3tj0GjS9t/vUSb986RTcbTldW2G4k0RrOABvnjhqKhyK7NAu06Sor2Glung8\nlOWrtAWgsXpmvMgr1Q0RpRrDRetdH2ftA3yc0+NfxjSk48kHht8Tc3EfJKtM\nw1rDFsDLnL+FUWaEMqYCwYIl93NvFkr958/VcmHB0lMc4tjEEUDlKAfyv17m\nV26x\r\n=/EUT\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBVXmlbEHtbVytxmqi2GXyUM/SHQC5V8N1oPY3t8FfOjAiEAkYlRI7M0X5wiEaLQoyUqxICuX+lcDIE1q/MXtVeIksE="}]},"maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/blob-util_2.0.2_1526942120197_0.28836420458634104"},"_hasShrinkwrap":false}},"readme":"blob-util [![Build Status](https://travis-ci.org/nolanlawson/blob-util.svg)](https://travis-ci.org/nolanlawson/blob-util) [![TypeScript](https://img.shields.io/badge/%3C%2F%3E-typescript-blue.svg)](http://www.typescriptlang.org/)\n=====\n\n`blob-util` is a [Blob](https://developer.mozilla.org/en-US/docs/Web/API/Blob?redirectlocale=en-US&redirectslug=DOM%2FBlob) library for busy people.\n\nIt offers a small set of cross-browser utilities for translating Blobs to and from different formats:\n\n* `<img/>` tags\n* base 64 strings\n* binary strings\n* ArrayBuffers\n* data URLs\n* canvas\n\nIt's also a good pairing with the attachment API in [PouchDB](http://pouchdb.com).\n\n**Note**: this is a browser library. For Node.js, see [Buffers](http://nodejs.org/api/buffer.html).\n\n**Topics**:\n\n* [Install](#usage)\n* [Browser support](#browser-support)\n* [Tutorial](#tutorial)\n* [Playground](http://nolanlawson.github.io/blob-util)\n* [API](#api)\n\nInstall\n------\n\nVia npm:\n\n```bash\nnpm install blob-util\n```\n\nES modules are supported:\n\n```js\nimport { canvasToBlob } from 'blob-util'\ncanvasToBlob(canvas, 'image/png').then(/* ... */)\n```\n\nOr as a script tag:\n\n```html\n<script src=\"https://unpkg.com/blob-util/dist/blob-util.min.js\"></script>\n```\n\nThen it's available as a global `blobUtil` object:\n\n```js\nblobUtil.canvasToBlob(canvas, 'image/png').then(/* ... */)\n```\n\nBrowser support\n-----\n\nAs of v2.0.0, a built-in `Promise` polyfill is no longer provided. Assuming you provide a `Promise`\npolyfill, the supported browsers are:\n\n* Firefox\n* Chrome\n* Edge\n* IE 10+\n* Safari 6+\n* iOS 6+\n* Android 4+\n* Any browser with either `Blob` or the older `BlobBuilder`; see [caniuse](http://caniuse.com/#search=blob) for details.\n\nTutorial\n--------\n\nBlobs (<strong>b</strong>inary <strong>l</strong>arge <strong>ob</strong>jects) are the modern way of working with binary data in the browser. The browser support is [very good](http://caniuse.com/#search=blob).\n\nOnce you have a Blob, you can make it available offline by storing it in [IndexedDB](http://www.w3.org/TR/IndexedDB/), [PouchDB](http://pouchdb.com/), [LocalForage](https://mozilla.github.io/localForage/), or other in-browser databases. So it's the perfect format for working with offline images, sound, and video.\n\nA [File](https://developer.mozilla.org/en-US/docs/Web/API/File) is also a Blob. So if you have an `<input type=\"file\">` in your page, you can let your users upload any file and then work with it as a Blob.\n\n### Example\n\nHere's Kirby. He's a famous little Blob.\n\n<img id=\"kirby\" alt=\"Kirby\" src=\"./test/kirby.gif\"/>\n\nSo let's fulfill his destiny, and convert him to a real `Blob` object.\n\n```js\nvar img = document.getElementById('kirby');\n\nblobUtil.imgSrcToBlob(img.src).then(function (blob) {\n  // ladies and gents, we have a blob\n}).catch(function (err) {\n  // image failed to load\n});\n```\n\n(Don't worry, this won't download the image twice, because browsers are smart.)\n\nNow that we have a `Blob`, we can convert it to a URL and use that as the source for another `<img/>` tag:\n\n```js\nvar blobURL = blobUtil.createObjectURL(blob);\n\nvar newImg = document.createElement('img');\nnewImg.src = blobURL;\n\ndocument.body.appendChild(newImg);\n```\n\nSo now we have two Kirbys - one with a normal URL, and the other with a blob URL. You can try this out yourself in the [blob-util playground](http://nolanlawson.github.io/blob-util). Super fun!\n\n<img src=\"blob-util.gif\"/>\n\n\nAPI\n-------\n\n<!-- begin insert API -->\n\n## Index\n\n### Functions\n\n* [arrayBufferToBinaryString](#arraybuffertobinarystring)\n* [arrayBufferToBlob](#arraybuffertoblob)\n* [base64StringToBlob](#base64stringtoblob)\n* [binaryStringToArrayBuffer](#binarystringtoarraybuffer)\n* [binaryStringToBlob](#binarystringtoblob)\n* [blobToArrayBuffer](#blobtoarraybuffer)\n* [blobToBase64String](#blobtobase64string)\n* [blobToBinaryString](#blobtobinarystring)\n* [blobToDataURL](#blobtodataurl)\n* [canvasToBlob](#canvastoblob)\n* [createBlob](#createblob)\n* [createObjectURL](#createobjecturl)\n* [dataURLToBlob](#dataurltoblob)\n* [imgSrcToBlob](#imgsrctoblob)\n* [imgSrcToDataURL](#imgsrctodataurl)\n* [revokeObjectURL](#revokeobjecturl)\n\n---\n\n## Functions\n\n<a id=\"arraybuffertobinarystring\"></a>\n\n###  arrayBufferToBinaryString\n\n▸ **arrayBufferToBinaryString**(buffer: *`ArrayBuffer`*): `string`\n\nConvert an `ArrayBuffer` to a binary string.\n\nExample:\n\n```js\nvar myString = blobUtil.arrayBufferToBinaryString(arrayBuff)\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| buffer | `ArrayBuffer` |  array buffer |\n\n**Returns:** `string`\nbinary string\n\n___\n<a id=\"arraybuffertoblob\"></a>\n\n###  arrayBufferToBlob\n\n▸ **arrayBufferToBlob**(buffer: *`ArrayBuffer`*, type?: *`string`*): `Blob`\n\nConvert an `ArrayBuffer` to a `Blob`.\n\nExample:\n\n```js\nvar blob = blobUtil.arrayBufferToBlob(arrayBuff, 'audio/mpeg');\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| buffer | `ArrayBuffer` |  - |\n| `Optional` type | `string` |  the content type (optional) |\n\n**Returns:** `Blob`\nBlob\n\n___\n<a id=\"base64stringtoblob\"></a>\n\n###  base64StringToBlob\n\n▸ **base64StringToBlob**(base64: *`string`*, type?: *`string`*): `Blob`\n\nConvert a base64-encoded string to a `Blob`.\n\nExample:\n\n```js\nvar blob = blobUtil.base64StringToBlob(base64String);\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| base64 | `string` |  base64-encoded string |\n| `Optional` type | `string` |  the content type (optional) |\n\n**Returns:** `Blob`\nBlob\n\n___\n<a id=\"binarystringtoarraybuffer\"></a>\n\n###  binaryStringToArrayBuffer\n\n▸ **binaryStringToArrayBuffer**(binary: *`string`*): `ArrayBuffer`\n\nConvert a binary string to an `ArrayBuffer`.\n\n```js\nvar myBuffer = blobUtil.binaryStringToArrayBuffer(binaryString)\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| binary | `string` |  binary string |\n\n**Returns:** `ArrayBuffer`\narray buffer\n\n___\n<a id=\"binarystringtoblob\"></a>\n\n###  binaryStringToBlob\n\n▸ **binaryStringToBlob**(binary: *`string`*, type?: *`string`*): `Blob`\n\nConvert a binary string to a `Blob`.\n\nExample:\n\n```js\nvar blob = blobUtil.binaryStringToBlob(binaryString);\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| binary | `string` |  binary string |\n| `Optional` type | `string` |  the content type (optional) |\n\n**Returns:** `Blob`\nBlob\n\n___\n<a id=\"blobtoarraybuffer\"></a>\n\n###  blobToArrayBuffer\n\n▸ **blobToArrayBuffer**(blob: *`Blob`*): `Promise`<`ArrayBuffer`>\n\nConvert a `Blob` to an `ArrayBuffer`.\n\nExample:\n\n```js\nblobUtil.blobToArrayBuffer(blob).then(function (arrayBuff) {\n  // success\n}).catch(function (err) {\n  // error\n});\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| blob | `Blob` |  - |\n\n**Returns:** `Promise`<`ArrayBuffer`>\nPromise that resolves with the `ArrayBuffer`\n\n___\n<a id=\"blobtobase64string\"></a>\n\n###  blobToBase64String\n\n▸ **blobToBase64String**(blob: *`Blob`*): `Promise`<`string`>\n\nConvert a `Blob` to a binary string.\n\nExample:\n\n```js\nblobUtil.blobToBase64String(blob).then(function (base64String) {\n  // success\n}).catch(function (err) {\n  // error\n});\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| blob | `Blob` |  - |\n\n**Returns:** `Promise`<`string`>\nPromise that resolves with the binary string\n\n___\n<a id=\"blobtobinarystring\"></a>\n\n###  blobToBinaryString\n\n▸ **blobToBinaryString**(blob: *`Blob`*): `Promise`<`string`>\n\nConvert a `Blob` to a binary string.\n\nExample:\n\n```js\nblobUtil.blobToBinaryString(blob).then(function (binaryString) {\n  // success\n}).catch(function (err) {\n  // error\n});\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| blob | `Blob` |  - |\n\n**Returns:** `Promise`<`string`>\nPromise that resolves with the binary string\n\n___\n<a id=\"blobtodataurl\"></a>\n\n###  blobToDataURL\n\n▸ **blobToDataURL**(blob: *`Blob`*): `Promise`<`string`>\n\nConvert a `Blob` to a data URL string (e.g. `'data:image/png;base64,iVBORw0KG...'`).\n\nExample:\n\n```js\nvar dataURL = blobUtil.blobToDataURL(blob);\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| blob | `Blob` |  - |\n\n**Returns:** `Promise`<`string`>\nPromise that resolves with the data URL string\n\n___\n<a id=\"canvastoblob\"></a>\n\n###  canvasToBlob\n\n▸ **canvasToBlob**(canvas: *`HTMLCanvasElement`*, type?: *`string`*, quality?: *`number`*): `Promise`<`Blob`>\n\nConvert a `canvas` to a `Blob`.\n\nExamples:\n\n```js\nblobUtil.canvasToBlob(canvas).then(function (blob) {\n  // success\n}).catch(function (err) {\n  // error\n});\n```\n\nMost browsers support converting a canvas to both `'image/png'` and `'image/jpeg'`. You may also want to try `'image/webp'`, which will work in some browsers like Chrome (and in other browsers, will just fall back to `'image/png'`):\n\n```js\nblobUtil.canvasToBlob(canvas, 'image/webp').then(function (blob) {\n  // success\n}).catch(function (err) {\n  // error\n});\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| canvas | `HTMLCanvasElement` |  HTMLCanvasElement |\n| `Optional` type | `string` |  the content type (optional, defaults to 'image/png') |\n| `Optional` quality | `number` |  a number between 0 and 1 indicating image quality if the requested type is 'image/jpeg' or 'image/webp' |\n\n**Returns:** `Promise`<`Blob`>\nPromise that resolves with the `Blob`\n\n___\n<a id=\"createblob\"></a>\n\n###  createBlob\n\n▸ **createBlob**(parts: *`Array`<`any`>*, properties?: * `BlobPropertyBag` &#124; `string`*): `Blob`\n\nShim for [`new Blob()`](https://developer.mozilla.org/en-US/docs/Web/API/Blob.Blob) to support [older browsers that use the deprecated `BlobBuilder` API](http://caniuse.com/blob).\n\nExample:\n\n```js\nvar myBlob = blobUtil.createBlob(['hello world'], {type: 'text/plain'});\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| parts | `Array`<`any`> |  content of the Blob |\n| `Optional` properties |  `BlobPropertyBag` &#124; `string`|  usually `{type: myContentType}`, you can also pass a string for the content type |\n\n**Returns:** `Blob`\nBlob\n\n___\n<a id=\"createobjecturl\"></a>\n\n###  createObjectURL\n\n▸ **createObjectURL**(blob: *`Blob`*): `string`\n\nShim for [`URL.createObjectURL()`](https://developer.mozilla.org/en-US/docs/Web/API/URL.createObjectURL) to support browsers that only have the prefixed `webkitURL` (e.g. Android <4.4).\n\nExample:\n\n```js\nvar myUrl = blobUtil.createObjectURL(blob);\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| blob | `Blob` |  - |\n\n**Returns:** `string`\nurl\n\n___\n<a id=\"dataurltoblob\"></a>\n\n###  dataURLToBlob\n\n▸ **dataURLToBlob**(dataURL: *`string`*): `Blob`\n\nConvert a data URL string (e.g. `'data:image/png;base64,iVBORw0KG...'`) to a `Blob`.\n\nExample:\n\n```js\nvar blob = blobUtil.dataURLToBlob(dataURL);\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| dataURL | `string` |  dataURL-encoded string |\n\n**Returns:** `Blob`\nBlob\n\n___\n<a id=\"imgsrctoblob\"></a>\n\n###  imgSrcToBlob\n\n▸ **imgSrcToBlob**(src: *`string`*, type?: *`string`*, crossOrigin?: *`string`*, quality?: *`number`*): `Promise`<`Blob`>\n\nConvert an image's `src` URL to a `Blob` by loading the image and painting it to a `canvas`.\n\nNote: this will coerce the image to the desired content type, and it will only paint the first frame of an animated GIF.\n\nExamples:\n\n```js\nblobUtil.imgSrcToBlob('http://mysite.com/img.png').then(function (blob) {\n  // success\n}).catch(function (err) {\n  // error\n});\n```\n```js\nblobUtil.imgSrcToBlob('http://some-other-site.com/img.jpg', 'image/jpeg',\n                         'Anonymous', 1.0).then(function (blob) {\n  // success\n}).catch(function (err) {\n  // error\n});\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| src | `string` |  image src |\n| `Optional` type | `string` |  the content type (optional, defaults to 'image/png') |\n| `Optional` crossOrigin | `string` |  for CORS-enabled images, set this to 'Anonymous' to avoid \"tainted canvas\" errors |\n| `Optional` quality | `number` |  a number between 0 and 1 indicating image quality if the requested type is 'image/jpeg' or 'image/webp' |\n\n**Returns:** `Promise`<`Blob`>\nPromise that resolves with the `Blob`\n\n___\n<a id=\"imgsrctodataurl\"></a>\n\n###  imgSrcToDataURL\n\n▸ **imgSrcToDataURL**(src: *`string`*, type?: *`string`*, crossOrigin?: *`string`*, quality?: *`number`*): `Promise`<`string`>\n\nConvert an image's `src` URL to a data URL by loading the image and painting it to a `canvas`.\n\nNote: this will coerce the image to the desired content type, and it will only paint the first frame of an animated GIF.\n\nExamples:\n\n```js\nblobUtil.imgSrcToDataURL('http://mysite.com/img.png').then(function (dataURL) {\n  // success\n}).catch(function (err) {\n  // error\n});\n```\n```js\nblobUtil.imgSrcToDataURL('http://some-other-site.com/img.jpg', 'image/jpeg',\n                         'Anonymous', 1.0).then(function (dataURL) {\n  // success\n}).catch(function (err) {\n  // error\n});\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| src | `string` |  image src |\n| `Optional` type | `string` |  the content type (optional, defaults to 'image/png') |\n| `Optional` crossOrigin | `string` |  for CORS-enabled images, set this to 'Anonymous' to avoid \"tainted canvas\" errors |\n| `Optional` quality | `number` |  a number between 0 and 1 indicating image quality if the requested type is 'image/jpeg' or 'image/webp' |\n\n**Returns:** `Promise`<`string`>\nPromise that resolves with the data URL string\n\n___\n<a id=\"revokeobjecturl\"></a>\n\n###  revokeObjectURL\n\n▸ **revokeObjectURL**(url: *`string`*): `void`\n\nShim for [`URL.revokeObjectURL()`](https://developer.mozilla.org/en-US/docs/Web/API/URL.revokeObjectURL) to support browsers that only have the prefixed `webkitURL` (e.g. Android <4.4).\n\nExample:\n\n```js\nblobUtil.revokeObjectURL(myUrl);\n```\n\n**Parameters:**\n\n| Param | Type | Description |\n| ------ | ------ | ------ |\n| url | `string` |   |\n\n**Returns:** `void`\n\n___\n\n\n\n<!-- end insert API -->\n\nCredits\n----\n\nThanks to the rest of [the PouchDB team](https://github.com/pouchdb/pouchdb/graphs/contributors) for figuring most of this crazy stuff out.\n\nBuilding the library\n----\n\n    npm install\n    npm run build\n\nTesting the library\n----\n\n    npm install\n\nThen to test in the browser using Saucelabs:\n\n    npm test\n\nOr to test locally in your browser of choice:\n\n    npm run test-local\n\nTo build the API docs and insert them in the README:\n\n    npm run doc","maintainers":[{"name":"nolanlawson","email":"nolan@nolanlawson.com"}],"time":{"modified":"2022-06-13T04:48:01.220Z","created":"2014-10-25T17:55:18.092Z","1.0.0":"2014-10-25T17:55:18.092Z","1.1.0":"2014-11-04T20:50:34.150Z","1.1.1":"2014-12-12T00:56:41.502Z","1.1.2":"2015-04-25T21:40:58.155Z","1.2.0":"2016-01-16T20:02:14.704Z","1.2.1":"2016-03-09T03:57:59.269Z","1.3.0":"2017-08-08T20:58:44.564Z","2.0.0":"2018-05-21T21:21:53.438Z","2.0.1":"2018-05-21T21:23:34.179Z","2.0.2":"2018-05-21T22:35:20.301Z"},"homepage":"https://github.com/nolanlawson/blob-util#readme","keywords":["blob","blobs","binary","util","utils"],"repository":{"type":"git","url":"git://github.com/nolanlawson/blob-util.git"},"author":{"name":"Nolan Lawson","email":"nolan.lawson@gmail.com"},"bugs":{"url":"https://github.com/nolanlawson/blob-util/issues"},"license":"Apache-2.0","readmeFilename":"README.md","users":{"klombomb":true,"classicoldsong":true,"andyhan":true,"shanewholloway":true}}