{"name":"crc32-stream","version":"7.0.0","keywords":["crc32-stream","crc32","stream","checksum"],"author":{"url":"http://christalkington.com/","name":"Chris Talkington"},"license":"MIT","_id":"crc32-stream@7.0.0","homepage":"https://github.com/archiverjs/node-crc32-stream","bugs":{"url":"https://github.com/archiverjs/node-crc32-stream/issues"},"dist":{"shasum":"f8630d972b4c36211646ecea7946a6bb61acc55f","tarball":"http://registry-npm.ywwl.com/crc32-stream/download/crc32-stream-7.0.0.tgz","fileCount":6,"integrity":"sha512-AmoDf2Lqvp3Eyq9LQszEcIMqPVNogMQHgSN1NbV70S+8NbDstYKW61ujNrmjiCgNpJHNpZ4bnOuC3yD6SUo7Vg==","signatures":[{"sig":"MEUCIAlOy+9K8N3Fmoj4Erfaj94L6eKqc9N+NKkX1ub2hGhYAiEAsjIqZXduHPiInhtMA11g5C19SNDsJdbVwDdJ5ZDac6I=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":6316,"size":2449,"noattachment":false,"key":"/crc32-stream/-/crc32-stream-7.0.0.tgz"},"type":"module","engines":{"node":">=18"},"exports":"./lib/index.js","gitHead":"d797b1d6febc3af36a998589c3528b86f58e9d97","scripts":{"test":"mocha --reporter dot"},"_npmUser":{"name":"ctalkington","email":"chris@talkingtontech.com"},"repository":{"url":"git+https://github.com/archiverjs/node-crc32-stream.git","type":"git"},"_npmVersion":"10.8.2","description":"a streaming CRC32 checksumer","directories":{},"_nodeVersion":"20.17.0","dependencies":{"crc-32":"^1.2.0","readable-stream":"^4.0.0"},"_hasShrinkwrap":false,"devDependencies":{"chai":"^5.1.1","mocha":"10.7.3"},"_npmOperationalInternal":{"tmp":"tmp/crc32-stream_7.0.0_1728852066046_0.9935453603113669","host":"s3://npm-registry-packages"},"readme":"# CRC32 Stream\n\ncrc32-stream is a streaming CRC32 checksumer. It uses the [crc](https://www.npmjs.org/package/crc) module behind the scenes to reliably handle binary data and fancy character sets. Data is passed through untouched.\n\n### Install\n\n```bash\nnpm install crc32-stream --save\n```\n\nYou can also use `npm install https://github.com/archiverjs/node-crc32-stream/archive/master.tar.gz` to test upcoming versions.\n\n### Usage\n\n#### CRC32Stream\n\nInherits [Transform Stream](http://nodejs.org/api/stream.html#stream_class_stream_transform) options and methods.\n\n```js\nimport { CRC32Stream } from \"crc32-stream\";\n\nconst source = fs.createReadStream(\"file.txt\");\nconst checksum = new CRC32Stream();\n\nchecksum.on(\"end\", function (err) {\n  // do something with checksum.digest() here\n});\n\n// either pipe it\nsource.pipe(checksum);\n\n// or write it\nchecksum.write(\"string\");\nchecksum.end();\n```\n\n#### DeflateCRC32Stream\n\nInherits [zlib.DeflateRaw](http://nodejs.org/api/zlib.html#zlib_class_zlib_deflateraw) options and methods.\n\n```js\nimport { DeflateCRC32Stream } from \"crc32-stream\";\n\nconst source = fs.createReadStream(\"file.txt\");\nconst checksum = new DeflateCRC32Stream();\n\nchecksum.on(\"end\", function (err) {\n  // do something with checksum.digest() here\n});\n\n// either pipe it\nsource.pipe(checksum);\n\n// or write it\nchecksum.write(\"string\");\nchecksum.end();\n```\n\n### Instance API\n\n#### digest()\n\nReturns the checksum digest in unsigned form.\n\n#### hex()\n\nReturns the hexadecimal representation of the checksum digest. (ie E81722F0)\n\n#### size(compressed)\n\nReturns the raw size/length of passed-through data.\n\nIf `compressed` is `true`, it returns compressed length instead. (DeflateCRC32Stream)\n\n## Things of Interest\n\n- [Changelog](https://github.com/archiverjs/node-crc32-stream/releases)\n- [Contributing](https://github.com/archiverjs/node-crc32-stream/blob/master/CONTRIBUTING.md)\n- [MIT License](https://github.com/archiverjs/node-crc32-stream/blob/master/LICENSE-MIT)\n","publish_time":1728852066241,"maintainers":[{"name":"ctalkington","email":"chris@talkingtontech.com"}],"_cnpm_publish_time":1728852066241,"dist-tags":{"latest":"7.0.1"}}