{"_id":"is-binary-buffer","_rev":"221011","name":"is-binary-buffer","description":"Returns true if a buffer is binary. Takes a buffer and does not read from the file system.","dist-tags":{"latest":"2.0.0"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"time":{"modified":"2021-06-03T15:39:58.000Z","created":"2017-05-19T20:36:10.698Z","2.0.0":"2018-03-07T12:13:17.048Z","1.0.0":"2017-05-19T20:38:29.002Z","0.1.0":"2017-05-19T20:36:10.698Z"},"users":{},"author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/is-binary-buffer.git"},"versions":{"2.0.0":{"name":"is-binary-buffer","description":"Returns true if a buffer is binary. Takes a buffer and does not read from the file system.","version":"2.0.0","homepage":"https://github.com/jonschlinkert/is-binary-buffer","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/is-binary-buffer.git"},"bugs":{"url":"https://github.com/jonschlinkert/is-binary-buffer/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=4"},"scripts":{"test":"mocha"},"dependencies":{"file-type":"^7.6.0","kind-of":"^6.0.2"},"devDependencies":{"gulp-format-md":"^1.0.0","mocha":"^3.5.3"},"keywords":["file","contents","vinyl","binary","buffer","is"],"verb":{"toc":false,"layout":"default","tasks":["readme"],"plugins":["gulp-format-md"],"lint":{"reflinks":true}},"gitHead":"ee73b647a0ceb89d0665ca79fc43bb992f337149","_id":"is-binary-buffer@2.0.0","_npmVersion":"5.7.1","_nodeVersion":"9.7.1","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"dist":{"shasum":"bb75e52dfc99c913419cc930095a9241b197452e","size":2605,"noattachment":false,"key":"/is-binary-buffer/-/is-binary-buffer-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/is-binary-buffer/download/is-binary-buffer-2.0.0.tgz"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/is-binary-buffer_2.0.0_1520424797000_0.733277703193898"},"_hasShrinkwrap":false,"publish_time":1520424797048,"_cnpm_publish_time":1520424797048},"1.0.0":{"name":"is-binary-buffer","description":"Returns true if a buffer is binary. Takes a buffer and does not read from the file system.","version":"1.0.0","homepage":"https://github.com/jonschlinkert/is-binary-buffer","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/is-binary-buffer.git"},"bugs":{"url":"https://github.com/jonschlinkert/is-binary-buffer/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=4"},"scripts":{"test":"mocha"},"dependencies":{"is-buffer":"^1.1.5"},"devDependencies":{"gulp-format-md":"^0.1.12","mocha":"^3.4.1"},"keywords":["binary","buffer","is"],"verb":{"toc":false,"layout":"default","tasks":["readme"],"plugins":["gulp-format-md"],"lint":{"reflinks":true}},"gitHead":"9b701819c17b58491b7ece59790bbb9eb6adc37d","_id":"is-binary-buffer@1.0.0","_shasum":"bc6031290b65cbf799b9d9502b50fd5375524007","_from":".","_npmVersion":"4.6.1","_nodeVersion":"7.7.3","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"bc6031290b65cbf799b9d9502b50fd5375524007","size":2963,"noattachment":false,"key":"/is-binary-buffer/-/is-binary-buffer-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/is-binary-buffer/download/is-binary-buffer-1.0.0.tgz"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/is-binary-buffer-1.0.0.tgz_1495226307968_0.8257288045715541"},"directories":{},"publish_time":1495226309002,"_hasShrinkwrap":false,"_cnpm_publish_time":1495226309002},"0.1.0":{"name":"is-binary-buffer","description":"Returns true if a buffer is binary. Takes a buffer and does not read from the file system.","version":"0.1.0","homepage":"https://github.com/jonschlinkert/is-binary-buffer","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/is-binary-buffer.git"},"bugs":{"url":"https://github.com/jonschlinkert/is-binary-buffer/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=4"},"scripts":{"test":"mocha"},"dependencies":{"is-buffer":"^1.1.5"},"devDependencies":{"gulp-format-md":"^0.1.12","mocha":"^3.4.1"},"keywords":["binary","buffer","is"],"verb":{"toc":false,"layout":"default","tasks":["readme"],"plugins":["gulp-format-md"],"lint":{"reflinks":true}},"gitHead":"9b701819c17b58491b7ece59790bbb9eb6adc37d","_id":"is-binary-buffer@0.1.0","_shasum":"6b9b9db4cf6d3a49626efa7fd4f78a4f3192a9a2","_from":".","_npmVersion":"4.6.1","_nodeVersion":"7.7.3","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"6b9b9db4cf6d3a49626efa7fd4f78a4f3192a9a2","size":2957,"noattachment":false,"key":"/is-binary-buffer/-/is-binary-buffer-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/is-binary-buffer/download/is-binary-buffer-0.1.0.tgz"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/is-binary-buffer-0.1.0.tgz_1495226169774_0.6476739982608706"},"directories":{},"publish_time":1495226170698,"_hasShrinkwrap":false,"_cnpm_publish_time":1495226170698}},"readme":"# is-binary-buffer [![NPM version](https://img.shields.io/npm/v/is-binary-buffer.svg?style=flat)](https://www.npmjs.com/package/is-binary-buffer) [![NPM monthly downloads](https://img.shields.io/npm/dm/is-binary-buffer.svg?style=flat)](https://npmjs.org/package/is-binary-buffer) [![NPM total downloads](https://img.shields.io/npm/dt/is-binary-buffer.svg?style=flat)](https://npmjs.org/package/is-binary-buffer) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/is-binary-buffer.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/is-binary-buffer)\n\n> Returns true if a buffer is binary. Takes a buffer and does not read from the file system.\n\nPlease consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support.\n\n## Install\n\nInstall with [npm](https://www.npmjs.com/):\n\n```sh\n$ npm install --save is-binary-buffer\n```\n\n## What is this?\n\nThis a node.js library written in pure javascript that can be used to check if the given value is a \"binary buffer\".\n\n## Usage\n\nYou can add this library to your node.js application using node's `require()` system with the following line of code:\n\n```js\nvar fs = require('fs');\nvar isBinary = require('is-binary-buffer');\n\nconsole.log(isBinary('foo'));             \nconsole.log(isBinary(new Buffer('foo'))); \n//=> false\n\nconsole.log(isBinary(fs.readFileSync('some-image.jpg'))); \nconsole.log(isBinary(fs.readFileSync('some-image.gif'))); \n//=> true\n```\n\n## Attribution\n\nBased on the code from [isbinaryfile](https://github.com/gjtorikian/isBinaryFile), which only reads from the file system. If the file doesn't exist, is a directory, or is empty, the function returns false.\n\n[isbinaryfile is MIT Licensed](https://github.com/gjtorikian/isBinaryFile/blob/b808cba3faa824bd3cade089743a714187af7193/LICENSE.txt)\n\n## About\n\n<details>\n<summary><strong>Contributing</strong></summary>\n\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).\n\nPlease read the [contributing guide](.github/contributing.md) for advice on opening issues, pull requests, and coding standards.\n\n</details>\n\n<details>\n<summary><strong>Running Tests</strong></summary>\n\nRunning and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:\n\n```sh\n$ npm install && npm test\n```\n\n</details>\n\n<details>\n<summary><strong>Building docs</strong></summary>\n\n_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_\n\nTo generate the readme, run the following command:\n\n```sh\n$ npm install -g verbose/verb#dev verb-generate-readme && verb\n```\n\n</details>\n\n### Author\n\n**Jon Schlinkert**\n\n* [LinkedIn Profile](https://linkedin.com/in/jonschlinkert)\n* [GitHub Profile](https://github.com/jonschlinkert)\n* [Twitter Profile](https://twitter.com/jonschlinkert)\n\n### License\n\nCopyright © 2018, [Jon Schlinkert](https://github.com/jonschlinkert).\nReleased under the [MIT License](LICENSE).\n\n***\n\n_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on March 07, 2018._","_attachments":{},"homepage":"https://github.com/jonschlinkert/is-binary-buffer","bugs":{"url":"https://github.com/jonschlinkert/is-binary-buffer/issues"},"license":"MIT"}