{"_id":"@cjser/is-jxr","name":"@cjser/is-jxr","dist-tags":{"latest":"2.0.0-cjser.2"},"versions":{"2.0.0-cjser.2":{"name":"@cjser/is-jxr","version":"2.0.0-cjser.2","description":"Check if a Buffer/Uint8Array is a JPEG XR image","license":"MIT","repository":{"type":"git","url":"https://code.moenext.com/3rdeye/cjser.git"},"funding":"https://github.com/sponsors/sindresorhus","author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"type":"module","exports":{"require":"./dist-cjser/index.cjs","default":"./index.js"},"engines":{"node":"^12.20.0 || ^14.13.1 || >=16.0.0"},"scripts":{"test":"xo && ava"},"keywords":["jxr","jpeg xr","jpg","jpeg","image","img","pic","picture","photo","type","detect","check","is","exif","binary","buffer","uint8array","cli","bin"],"devDependencies":{"ava":"^3.15.0","read-chunk":"^4.0.2","xo":"^0.44.0"},"main":"./dist-cjser/index.cjs","cjser":{"sourceVersion":"2.0.0","cjserVersion":2,"original":{"name":"is-jxr","version":"2.0.0","exports":"./index.js","repository":"sindresorhus/is-jxr","files":["index.js"],"scripts":{"test":"xo && ava"}}},"_id":"@cjser/is-jxr@2.0.0-cjser.2","gitHead":"a4bef54d7d22d3d9a6b84528457938d84cd65fe7","_nodeVersion":"20.14.0","_npmVersion":"10.7.0","dist":{"integrity":"sha512-4/JEAmDfymPDZTtva7BhGxCCd5OUmXXP9TzIF0pWqrbQIELxdQjDlu+DV4RNCJXjwHCtraWD0ty6n9XLs1i9QA==","shasum":"6c8a03a0b8e1dbd22793280f9a17c3fa63a69ef8","tarball":"https://registry.npmjs.org/@cjser/is-jxr/-/is-jxr-2.0.0-cjser.2.tgz","fileCount":5,"unpackedSize":4891,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQDdhvVDEZeyY+wMpDNZp+7fKg5hrThgGIZBIO/6Me/jCwIhANik4Zhcbt0xp1M/PolEEAljfSft4pnRscnbKqAhAKPp"}]},"_npmUser":{"name":"nanahira","email":"nanahira@momobako.com"},"directories":{},"maintainers":[{"name":"nanahira","email":"nanahira@momobako.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/is-jxr_2.0.0-cjser.2_1778158752569_0.34997708825294294"},"_hasShrinkwrap":false}},"time":{"created":"2026-05-07T12:59:12.473Z","2.0.0-cjser.2":"2026-05-07T12:59:12.729Z","modified":"2026-05-07T12:59:12.954Z"},"maintainers":[{"name":"nanahira","email":"nanahira@momobako.com"}],"description":"Check if a Buffer/Uint8Array is a JPEG XR image","keywords":["jxr","jpeg xr","jpg","jpeg","image","img","pic","picture","photo","type","detect","check","is","exif","binary","buffer","uint8array","cli","bin"],"repository":{"type":"git","url":"https://code.moenext.com/3rdeye/cjser.git"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"license":"MIT","readme":"# is-jxr\n\n> Check if a Buffer/Uint8Array is a [JPEG XR](https://en.wikipedia.org/wiki/JPEG_XR) image\n\n## Install\n\n```sh\nnpm install is-jxr\n```\n\n## Usage\n\n##### Node.js\n\n```js\nimport {readChunk} from 'read-chunk';\nimport isJxr from 'is-jxr';\n\nconst buffer = await readChunk('unicorn.jxr', {length: 3});\n\nisJxr(buffer);\n//=> true\n```\n\n##### Browser\n\n```js\nconst xhr = new XMLHttpRequest();\nxhr.open('GET', 'unicorn.jxr');\nxhr.responseType = 'arraybuffer';\n\nxhr.onload = () => {\n\tisJxr(new Uint8Array(this.response));\n\t//=> true\n};\n\nxhr.send();\n```\n\n## API\n\n### isJxr(buffer)\n\nAccepts a `Buffer` (Node.js) or `Uint8Array`.\n\nIt only needs the first 3 bytes.\n\n## Related\n\n- [file-type](https://github.com/sindresorhus/file-type) - Detect the file type of a Buffer/Uint8Array\n\n## cjser\n\nThis package is a CommonJS-compatible build generated by cjser for projects that still need `require()` support. The source version matches the original npm package version, with a cjser prerelease suffix for this generated build.\nOriginal repository: https://github.com/sindresorhus/is-jxr\n","readmeFilename":"readme.md","_rev":"1-5971f8519be521961f88e2eec297001b"}