{"_id":"is-bmp","_rev":"11-bbd4c995f50d688b846af584f30a9642","name":"is-bmp","description":"Check if a Buffer/Uint8Array is a BMP image","dist-tags":{"latest":"2.0.0"},"versions":{"0.1.0":{"name":"is-bmp","version":"0.1.0","description":"Check if a Buffer/Uint8Array is a BMP image","license":"MIT","repository":{"type":"git","url":"git://github.com/sindresorhus/is-bmp"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"http://sindresorhus.com"},"engines":{"node":">=0.10.0"},"scripts":{"test":"mocha","browser":"browserify -s $npm_package_name -o browser.js ."},"files":["index.js"],"keywords":["bmp","bitmap","graphics","image","img","pic","picture","photo","type","detect","check","is","exif","binary","buffer","uint8array"],"devDependencies":{"browserify":"^3.0.0","mocha":"*","read-chunk":"^0.1.0"},"bugs":{"url":"https://github.com/sindresorhus/is-bmp/issues"},"homepage":"https://github.com/sindresorhus/is-bmp","_id":"is-bmp@0.1.0","dist":{"shasum":"d8ea726ca8ee20b06ac3c5e04dd61af4bf5622fa","tarball":"https://registry.npmjs.org/is-bmp/-/is-bmp-0.1.0.tgz","integrity":"sha512-3qmf7T1zPXU5pSM4LlE8VQZ9uUYvFwgkBYOwQp0LPTimoS8UkbMlbfMQNoniZuXjY2hqia+aUrXUE1Gh9egMMg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD/Gn/Y+Jx8h7jDeCGHYMrrPRluh789BS6GB/lVbzNUkgIgEoZf2IirNfSaWtqsRCextSL6iI1rosfooOLIzXcokxU="}]},"_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"directories":{}},"0.1.1":{"name":"is-bmp","version":"0.1.1","description":"Check if a Buffer/Uint8Array is a BMP image","license":"MIT","repository":{"type":"git","url":"git://github.com/sindresorhus/is-bmp"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"http://sindresorhus.com"},"engines":{"node":">=0.10.0"},"scripts":{"test":"mocha","browser":"browserify -s $npm_package_name -o browser.js ."},"files":["index.js"],"keywords":["bmp","bitmap","graphics","image","img","pic","picture","photo","type","detect","check","is","exif","binary","buffer","uint8array"],"devDependencies":{"browserify":"^3.0.0","mocha":"*","read-chunk":"^0.1.0"},"bugs":{"url":"https://github.com/sindresorhus/is-bmp/issues"},"homepage":"https://github.com/sindresorhus/is-bmp","_id":"is-bmp@0.1.1","dist":{"shasum":"4efaf2199399d70ef5f7a1a4db3bc2c9dd50b5d3","tarball":"https://registry.npmjs.org/is-bmp/-/is-bmp-0.1.1.tgz","integrity":"sha512-UqYtqLTLhMa8Kd54eSScvixHrr+PC2+IIhuETREF6qn00YUtjsbBC/e6YNxkjEgfs27AuMzkM0olSc9mepuK0g==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAxur/LqLsPY6SXZGSfpkaDQdUtlenqgXsLs70VIIPXnAiBe9MV6wlQSpjiX/QgO07t/mAV9dbFkUN7k6oYEYRWNBg=="}]},"_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"directories":{}},"1.0.0":{"name":"is-bmp","version":"1.0.0","description":"Check if a Buffer/Uint8Array is a BMP image","license":"MIT","repository":{"type":"git","url":"https://github.com/sindresorhus/is-bmp"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"http://sindresorhus.com"},"engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"files":["index.js"],"keywords":["bmp","bitmap","graphics","image","img","pic","picture","photo","type","detect","check","is","exif","binary","buffer","uint8array"],"devDependencies":{"mocha":"*","read-chunk":"^1.0.0"},"gitHead":"7f596a77313e1c736a21427b97d14720af5a8980","bugs":{"url":"https://github.com/sindresorhus/is-bmp/issues"},"homepage":"https://github.com/sindresorhus/is-bmp","_id":"is-bmp@1.0.0","_shasum":"f1866f1709cea3d4d2cf458a6347bb1df3657199","_from":".","_npmVersion":"1.4.21","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"dist":{"shasum":"f1866f1709cea3d4d2cf458a6347bb1df3657199","tarball":"https://registry.npmjs.org/is-bmp/-/is-bmp-1.0.0.tgz","integrity":"sha512-Z2S0xQKZzEHUiAaCERitzreSPqY1SdVcBMveg0UmRo1TlcBn2G0eqZMIU9gIfUFxY+zx0ctgkXB35HUF4/wF2Q==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHebCQbhUhK1rDkkaxwv+5zIS1GUpj/AcnwzWRHwGugBAiB7ecizb6bsK0++dDG8M262HyQoiz356aEOzNTFLK3lgQ=="}]},"directories":{}},"1.0.1":{"name":"is-bmp","version":"1.0.1","description":"Check if a Buffer/Uint8Array is a BMP image","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/is-bmp.git"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"http://sindresorhus.com"},"engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"files":["index.js"],"keywords":["bmp","bitmap","graphics","image","img","pic","picture","photo","type","detect","check","is","exif","binary","buffer","uint8array"],"devDependencies":{"mocha":"*","read-chunk":"^1.0.0"},"gitHead":"9597717d8d9b251db7b4d3815fe83704985df9f4","bugs":{"url":"https://github.com/sindresorhus/is-bmp/issues"},"homepage":"https://github.com/sindresorhus/is-bmp#readme","_id":"is-bmp@1.0.1","_npmVersion":"5.6.0","_nodeVersion":"8.10.0","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"dist":{"integrity":"sha512-xMHM1A7OssYXcA/6hMN222KVQkSAG2HxnzGqKl6Kgzh+Dapj9bMI4UeGd3deytw/DpptGAq1HPDHQhWQtis+Ew==","shasum":"eec4e8620a2da9c89c7d99782688e41c41b9d589","tarball":"https://registry.npmjs.org/is-bmp/-/is-bmp-1.0.1.tgz","fileCount":4,"unpackedSize":2912,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIB/ccIPpnw6DJTGhS6SHtx7vZS6Mwhz6a0hV/1Rd5cr7AiAzxJS/on6VCX0Stj9MYXQzVOxFYm5vLMhXU/SVec0wIg=="}]},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/is-bmp_1.0.1_1521736519668_0.6947538960996473"},"_hasShrinkwrap":false},"2.0.0":{"name":"is-bmp","version":"2.0.0","description":"Check if a Buffer/Uint8Array is a BMP image","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/is-bmp.git"},"funding":"https://github.com/sponsors/sindresorhus","author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"type":"module","exports":"./index.js","engines":{"node":"^12.20.0 || ^14.13.1 || >=16.0.0"},"scripts":{"test":"xo && ava"},"keywords":["bmp","bitmap","graphics","image","picture","photo","type","detect","check","is","exif","binary","buffer","uint8array"],"devDependencies":{"ava":"^3.15.0","read-chunk":"^4.0.1","xo":"^0.44.0"},"gitHead":"04ccd3fd23acfbd4bffbb88718824bafa0ff19d7","bugs":{"url":"https://github.com/sindresorhus/is-bmp/issues"},"homepage":"https://github.com/sindresorhus/is-bmp#readme","_id":"is-bmp@2.0.0","_nodeVersion":"14.17.5","_npmVersion":"7.20.3","dist":{"integrity":"sha512-HF12soYuTMOqVYhoxFgV87yuMEOYjtGBWfetHySJ6XX2sm47vWTd1BKWzas7RF/Xfld8m4QV51M8pIjK0FEfSw==","shasum":"fb995f2e6dfabfecd904b8c9d202a936d4d03153","tarball":"https://registry.npmjs.org/is-bmp/-/is-bmp-2.0.0.tgz","fileCount":4,"unpackedSize":2820,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhMNxKCRA9TVsSAnZWagAAEIQP/jDzeA9z/AE/7hjknF7D\n2i7w42/MuBMziQgrCMMZBFOlQPSJJLqd8hsgqkd19Eqa0Isq8n1JmOGStYj1\nOTRrzLW7T4uvPD9zdNGHTSiGjneY/WDfWAwKsVzwC6SSdNTRF0trXZNZZT9e\n3INpRMhmCbWlZWUMCwTnOXygRuhu2wQnqMaXfNWrYGd/bMK8mJNI9OnwAElB\nD2dW1Xh66+rfr+fxNwiSqFY77VFDn4QvzKBA242kXgBBKOu4rK79+c3ietk3\nDfe2CdWYsCKvxYMSJcscf2unbawR2W3qU0/yKrl8UcHPDaCbNv0E3VGznmQO\n3CIvhfYB+w3FzsVgNEdz+v15OqvHpvYvYbXBEg+jiiIofrpJS8iRfHQJzGlq\neXE6O1OOeA7uqGNIa5fDFBr5eFPphDiWg2ZAJoxhd6jbDHHtsosfn2ah4snl\nluprAkWtiPPIjUrcbwdKNggx1zBzw5RkGaa1wERprAZSl0fHaFg5llzoVbv+\nA7Lrh6f8Qt9kCxBf8S9Khiym0G1Z28jwVe3yjj0cMULQC9RhQFLjfW7rKSer\nrfbyuveES/Es0gtrSREnXn6589XNPKEXNWz3HqR6aknib+VkIsXE8OFm9iri\nvCwM0qaz4h4fvCU32ljfv37b9YYGsHPjuPTXALWU2o+IIs8q675kr7iE0xrs\nyg5U\r\n=9QU/\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCf7QCDi9Ek+uSREFlxhj9gAUcDjHgx2dkrG30RwZR0fgIgAP0ktNH3mhIPi1IcaAH+ZP5UZw2x43m3RatA136PU1c="}]},"_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"directories":{},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/is-bmp_2.0.0_1630592074147_0.10883862237007347"},"_hasShrinkwrap":false}},"readme":"# is-bmp\n\n> Check if a Buffer/Uint8Array is a [BMP](https://en.m.wikipedia.org/wiki/BMP_file_format) image\n\n## Install\n\n```\n$ npm install is-bmp\n```\n\n## Usage\n\n##### Node.js\n\n```js\nimport {readChunk} from 'read-chunk';\nimport isBmp from 'is-bmp';\n\nconst buffer = await readChunk('unicorn.bmp', {length: 2});\n\nisBmp(buffer);\n//=> true\n```\n\n##### Browser\n\n```js\nconst xhr = new XMLHttpRequest();\nxhr.open('GET', 'unicorn.bmp');\nxhr.responseType = 'arraybuffer';\n\nxhr.onload = () => {\n\tisBmp(new Uint8Array(this.response));\n\t//=> true\n};\n\nxhr.send();\n```\n\n## API\n\n### isBmp(buffer)\n\nAccepts a `Buffer` (Node.js) or `Uint8Array`.\n\nIt only needs the first 2 bytes.\n\n## Related\n\n- [file-type](https://github.com/sindresorhus/file-type) - Detect the file type of a Buffer/Uint8Array\n","maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"time":{"modified":"2022-06-19T02:37:30.000Z","created":"2014-04-21T17:36:24.371Z","0.1.0":"2014-04-21T17:36:24.371Z","0.1.1":"2014-04-29T19:08:10.619Z","1.0.0":"2014-08-14T14:40:19.318Z","1.0.1":"2018-03-22T16:35:19.776Z","2.0.0":"2021-09-02T14:14:34.280Z"},"homepage":"https://github.com/sindresorhus/is-bmp#readme","keywords":["bmp","bitmap","graphics","image","picture","photo","type","detect","check","is","exif","binary","buffer","uint8array"],"repository":{"type":"git","url":"git+https://github.com/sindresorhus/is-bmp.git"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"bugs":{"url":"https://github.com/sindresorhus/is-bmp/issues"},"license":"MIT","readmeFilename":"readme.md"}