{"name":"is-cwebp-readable","version":"3.0.0-0","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"},"license":"CC0-1.0","scripts":{"bench":"node -p \"require('chalk').yellow('NOTE: Smaller is better.\\n')\" && node benchmark/array-index-of.js && node benchmark/array-includes.js && node benchmark/keys.js && node benchmark/logical-or.js && node benchmark/regexp-test.js && node benchmark/set.js && node -p \"''\"","pretest":"eslint .","test":"nyc node test.js"},"keywords":["buffer","uint8array","type","file","detect","image","jpg","jpeg","png","tif","tiff","webp","cwebp"],"dependencies":{"file-type":"^10.5.0"},"devDependencies":{"@shinnn/eslint-config":"^6.8.1","chalk":"^2.4.1","eslint":"^5.9.0","nyc":"^13.1.0","nyc-config-common":"^1.0.1","tape":"^4.9.1"},"eslintConfig":{"extends":"@shinnn"},"nyc":{"extends":"nyc-config-common"},"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.org/shinnn/is-cwebp-readable.svg?branch=master)](https://travis-ci.org/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 npm.](https://docs.npmjs.com/cli/install)\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`](http://www.ecma-international.org/ecma-262/6.0/#sec-typedarray-objects)  \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[Creative Commons Zero v1.0 Universal](https://creativecommons.org/publicdomain/zero/1.0/deed)\n","readmeFilename":"README.md","gitHead":"714d3afceb328206e028ec083bc730a9efcad8c9","bugs":{"url":"https://github.com/shinnn/is-cwebp-readable/issues"},"homepage":"https://github.com/shinnn/is-cwebp-readable#readme","_id":"is-cwebp-readable@3.0.0-0","_npmVersion":"6.5.0","_nodeVersion":"11.4.0","_npmUser":{"name":"shinnn","email":"snnskwtnb@gmail.com"},"maintainers":[{"name":"shinnn","email":"snnskwtnb@gmail.com"}],"dist":{"integrity":"sha512-h7wNUN31LbdoC9cJyt8yx4zdu6Cm912I23GPp9gmQRXsPV0j1Zb6eE6l0pbX8BlEv5AWqYH6FABWaZpvuH60fQ==","shasum":"12e3a1423ec0a623524c6284bcbbdf5814b1e42e","tarball":"http://registry-npm.ywwl.com/is-cwebp-readable/download/is-cwebp-readable-3.0.0-0.tgz","fileCount":3,"unpackedSize":2925,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcF6Z1CRA9TVsSAnZWagAALnoP/A/7nKFTmFooVCex6S5C\n7XYkxZjmpmWpwrGZyXic6cErM/VZDhAd6CqpkiKSp13o3O82apLYE9yND0tY\n37XNgH3FRDNIg4YZbBj8s3WAUEgGnWPFSV6Gayx/6tCQrDspLIf28nyC5y8i\nHp6kgI+8Ct5+AWzQcwQRmVz9JCCJlGPpZorDAO5yqPtiDFZ02QcLaVOjaqhZ\nVDI5JzM2oMENOZv26tMTdx9mflzXrjjIX/Rp4DfTSGyZLI68XRBKJ7RmR5Za\nfgH6xLBwmcThiQBXCF1YuqYphuNiPedIX6aywEBRPrPY9w8/swx7epywz4Zs\niIxQvnW478ZNsa9IYPfxutxubpu/VmO1mNXkVou48apksPEeR7iYV6IWEPMB\nO9/MHfFEHglg3zYW6tCDZ8FvACsMn8otyeN2vp05VVPUy2+Z0QdiTGXF2K4i\nY7TJJ5BhcP9baSAOflPlc/zPaqj8gCDkFZebj+St7sizibLu3k3V/fNARs3F\nicXSc+SNxIazlRz+o5z5DlGk6IoFuKrsbBqmX5TBgYQkUPGVY7ndMFVlC+u7\nan2WihOoXeQcedK3w552ydKL7pdyY4GLT1g38xi4i2V0OnLKyZLUFUne4aii\njE/xtiRm+rFRbi4GiYvkr8SGI8zlcdbEptwO58voGwsUqBBePzvcyQdoMGv2\nYeYg\r\n=7OLj\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGQ0wNKwsTKsNwpW+U2Aoaf1cCsVc0XXz+Snr2gJGqndAiBiXhYKR/uop6Z6prh7NlwL8Nzh1FhyPC+11pAtP3H2zA=="}],"size":1424,"noattachment":false,"key":"/is-cwebp-readable/-/is-cwebp-readable-3.0.0-0.tgz"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/is-cwebp-readable_3.0.0-0_1545053812565_0.9340963645021005"},"_hasShrinkwrap":false,"publish_time":1545053812670,"_cnpm_publish_time":1545053812670,"dist-tags":{"latest":"3.0.0","next":"3.0.0-1"}}