{"name":"is-cwebp-readable","version":"1.0.2","description":"Check if a Buffer/Uint8Array is available for cwebp image source","repository":{"type":"git","url":"git+https://github.com/shinnn/is-cwebp-readable.git"},"author":{"name":"Shinnosuke Watanabe","url":"https://github.com/shinnn"},"scripts":{"bench":"node --harmony_arrow_functions node_modules/.bin/_matcha benchmark/runner.js","pretest":"eslint --config node_modules/@shinnn/eslintrc-node/rc.json index.js benchmark test.js","test":"node --harmony_arrow_functions test.js | tap-spec","coverage":"node --harmony_arrow_functions node_modules/.bin/istanbul cover test.js","coveralls":"${npm_package_scripts_coverage} && istanbul-coveralls"},"license":"Unlicense","files":["index.js"],"keywords":["buffer","uint8array","type","file","detect","image","jpg","jpeg","png","tif","tiff","webp","cwebp"],"dependencies":{"file-type":"^2.6.0"},"devDependencies":{"@shinnn/eslintrc-node":"^1.0.2","eslint":"^0.21.2","istanbul":"^0.3.14","istanbul-coveralls":"^1.0.2","matcha":"^0.6.0","tap-spec":"^3.0.0","tape":"^4.0.0"},"gitHead":"7c6c892163a16747c451d2ffd57f17424f926cf6","bugs":{"url":"https://github.com/shinnn/is-cwebp-readable/issues"},"homepage":"https://github.com/shinnn/is-cwebp-readable#readme","_id":"is-cwebp-readable@1.0.2","_shasum":"66d62eebe94bad14282ccd2e20e4f83775ecd711","_from":".","_npmVersion":"2.10.1","_nodeVersion":"2.1.0","_npmUser":{"name":"shinnn","email":"snnskwtnb@gmail.com"},"maintainers":[{"name":"shinnn","email":"snnskwtnb@gmail.com"}],"dist":{"shasum":"66d62eebe94bad14282ccd2e20e4f83775ecd711","tarball":"http://registry-npm.ywwl.com/is-cwebp-readable/download/is-cwebp-readable-1.0.2.tgz","integrity":"sha512-/1Vp7piXBF9KsIw/XWN9lSlJkCaNkQpQiBYjI5MdrUi6SdRSljyQXoSQsjacuHT36EvqVujM8qr2GMn+RUsaAQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD0XXdBWx0LPin4zj5GTYsG4Zhq/2bkxj7QOw/KLcCJEwIhAJJj1EfMvibfrq7fq38Rv/I6UHaajmceeBp6Y5WFl8hh"}],"size":2230,"noattachment":false,"key":"/is-cwebp-readable/-/is-cwebp-readable-1.0.2.tgz"},"directories":{},"readme":"# is-cwebp-readable\n\n[![npm version](https://img.shields.io/npm/v/is-cwebp-readable.svg)](https://www.npmjs.com/package/is-cwebp-readable)\n[![Build Status](https://travis-ci.com/shinnn/is-cwebp-readable.svg?branch=master)](https://travis-ci.com/shinnn/is-cwebp-readable)\n[![Coverage Status](https://img.shields.io/coveralls/shinnn/is-cwebp-readable.svg)](https://coveralls.io/github/shinnn/is-cwebp-readable)\n\nCheck if a Buffer/Uint8Array is available for [cwebp](https://developers.google.com/speed/webp/docs/cwebp) image source\n\n```javascript\nconst {readFileSync} = require('fs');\nconst isCwebpReadable = require('is-cwebp-readable');\n\nisCwebpReadable(readFileSync('fixture.png')); //=> true\nisCwebpReadable(readFileSync('fixture.bmp')); //=> false\n```\n\n## Installation\n\n[Use](https://docs.npmjs.com/cli/install) [npm](https://docs.npmjs.com/about-npm/).\n\n```\nnpm install is-cwebp-readable\n```\n\n## API\n\n```javascript\nconst isCwebpReadable = require('is-cwebp-readable');\n```\n\n### isCwebpReadable(*data*)\n\n*data*: [`Buffer`](https://nodejs.org/api/buffer.html#buffer_class_buffer) or [`Uint8Array`](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array)  \nReturn: `boolean`\n\nIt returns `true` if the data is [PNG](https://wikipedia.org/wiki/Portable_Network_Graphics), [JPEG](https://wikipedia.org/wiki/JPEG), [TIFF](https://wikipedia.org/wiki/Tagged_Image_File_Format), or [WebP](https://wikipedia.org/wiki/WebP), otherwise `false`.\n\n## License\n\n[ISC License](./LICENSE) © 2018 Shinnosuke Watanabe\n","publish_time":1432902769857,"_cnpm_publish_time":1432902769857,"dist-tags":{"latest":"3.0.0","next":"3.0.0-1"}}