{"_id":"@dstanesc/wasm-chunking-webpack-eval","name":"@dstanesc/wasm-chunking-webpack-eval","dist-tags":{"latest":"0.1.0"},"versions":{"0.1.0":{"name":"@dstanesc/wasm-chunking-webpack-eval","decription":"Wasm library for content-based slicing for bundlers such as Webpack. Convenience wrapper on existing rolling hash implementations in rust","homepage":"https://github.com/dstanesc/wasm-chunking-eval","repository":{"type":"git","url":"git+https://github.com/dstanesc/wasm-chunking-eval.git"},"license":"MIT, Apache 2.0, BSD-2-Clause-Patent","author":{"name":"Hexagon and contributors"},"collaborators":["dstanesc"],"version":"0.1.0","module":"chunking.js","types":"chunking.d.ts","sideEffects":false,"gitHead":"b51b0a213994aa6e9a0f4ca388bcd4bd505570e6","description":"[Wasm](https://github.com/rustwasm/wasm-pack) library for [content-based slicing](https://en.wikipedia.org/wiki/Rolling_hash). Convenience wrapper on existing rolling hash implementations in rust, such as provided by [fastcdc](https://github.com/nlfiedler","bugs":{"url":"https://github.com/dstanesc/wasm-chunking-eval/issues"},"_id":"@dstanesc/wasm-chunking-webpack-eval@0.1.0","_nodeVersion":"16.13.1","_npmVersion":"8.17.0","dist":{"integrity":"sha512-jX9SwZkwgz2QVrm/STspk7XGwUW7TPKGYzt3I03JojmQRX6zhglEid960T8CLncQ85NNiV1pX8lAmFHxhBf52g==","shasum":"a992a792df9888067ac4b608d708fc3ff08521a6","tarball":"https://registry.npmjs.org/@dstanesc/wasm-chunking-webpack-eval/-/wasm-chunking-webpack-eval-0.1.0.tgz","fileCount":6,"unpackedSize":73635,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDExUHEhOUi3Z4NcXoUYrq7mOGg9SUpMgGRu2WdeUK32AIhAI60UgaNdoNkyb0MXdfVA1kN29bIGXLdZpC+rto0xawP"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi/prPACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmp9oQ//QdO2j8/YIdGhBU8RUoSCvumqHKjCNS2dnrxw4JqRlFwtnuLq\r\nzItJfaJRYNNa9SGXu7jPrScd/PKJD87BXy+NTLwJHSkm4Rr28cA7wPVdfGtB\r\nMfiee+ucjQv8+E6IVw67NABTky2eRcrh7gLMwR7k+oOPf71RBFbb9QEAps8C\r\nj71tudrSyL2dlfs9LI6h1CemU0+MWL/QLOH0jWb2J/pt7+2M4pc9tbBfzalp\r\n2iltC9DOyET7Qwon5+q4gqUGyUl4Lovsux+uSI2AEHqdu0+XoWlUMu1G5NSP\r\nKuAiYifo6XiQmaQQ6+WNIkabRDYGhvM47w/06yv742o+WgqeM0jXvjS8btj3\r\nwOHFzUJgQ39lYw2VmcbTXxbiEs+ytlaK0+j4fEBfej0+QSdx20n9bBtaKzqE\r\nBmnZIaRd0zbuPlpa98s4hVYdspjdHi+la70XrVHBQMz5QsQ6pkOEM4hFZTab\r\nUkhQNdcv7bsC1GumIrqgH9u8BXRHeFf5nRakjORaAUVwyIG5934FQNDufiwj\r\nfcRt3101Emgff3oR25sDy0T2Gr4GcrDo+/+M8zkHjCTl1XnjqFQCOmQLrSHe\r\nkBScc4yo3u6ASsfB+2iKzUZoBvI7iUwOZZQt+v8tAVg9BItqqzx1nnHpuVTN\r\nV3bOUhnKpmUp5iz9CrNWJr0IhH3SihlHOBE=\r\n=uBpD\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"dstanesc","email":"dstanesc@gmail.com"},"directories":{},"maintainers":[{"name":"dstanesc","email":"dstanesc@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/wasm-chunking-webpack-eval_0.1.0_1660852942888_0.7208791482550121"},"_hasShrinkwrap":false}},"time":{"created":"2022-08-18T20:02:22.844Z","0.1.0":"2022-08-18T20:02:23.043Z","modified":"2022-08-18T20:02:23.227Z"},"maintainers":[{"name":"dstanesc","email":"dstanesc@gmail.com"}],"description":"[Wasm](https://github.com/rustwasm/wasm-pack) library for [content-based slicing](https://en.wikipedia.org/wiki/Rolling_hash). Convenience wrapper on existing rolling hash implementations in rust, such as provided by [fastcdc](https://github.com/nlfiedler","homepage":"https://github.com/dstanesc/wasm-chunking-eval","repository":{"type":"git","url":"git+https://github.com/dstanesc/wasm-chunking-eval.git"},"author":{"name":"Hexagon and contributors"},"bugs":{"url":"https://github.com/dstanesc/wasm-chunking-eval/issues"},"license":"MIT, Apache 2.0, BSD-2-Clause-Patent","readme":"\n## Wasm Content Defined Chunking Evaluation \n\n[Wasm](https://github.com/rustwasm/wasm-pack) library for [content-based slicing](https://en.wikipedia.org/wiki/Rolling_hash). Convenience wrapper on existing rolling hash implementations in rust, such as provided by [fastcdc](https://github.com/nlfiedler/fastcdc-rs), [asuran chunker](https://gitlab.com/asuran-rs/asuran), etc. \n\n\n## Build Requirements\n\n- [Rust toolchain](https://www.rust-lang.org/tools/install)\n- [Wasm-pack](https://rustwasm.github.io/wasm-pack/installer/)\n\n## Test\n\n```sh\nwasm-pack test --headless --firefox\n```\n\n## Wasm Build\n\n```sh\nwasm-pack build --out-dir pkg/webpack --out-name chunking --target bundler --scope dstanesc\nwasm-pack build --out-dir pkg/node --out-name chunking --target nodejs --scope dstanesc\n```\n\n## Install for NodeJS\n\n```\nnpm install @dstanesc/wasm-chunking-node-eval\n```\n\n## Install for Webpack bundling\n\n```\nnpm install @dstanesc/wasm-chunking-webpack-eval\n```\n\n## Usage\n\n```js\nimport {compute_chunks_buzhash, compute_chunks_fastcdc} from \"@dstanesc/wasm-chunking-node-eval\";\n\nconst buf = ...\n// mask 0b11111111111111\nconst offsets_buz = compute_chunks_buzhash(buf, 15).values(); \n// chunk sizes: min 16 KiB, avg 32 KiB, max 64 KiB\nconst offsets_fast = compute_chunks_fastcdc(buf, 16384, 32768, 65536).values();   \n```\n\n## Licenses\n\nLicensed under either of\n\n* Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or http://www.apache.org/licenses/LICENSE-2.0)\n* MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT)\n\nat your option.\n\n[Fastcdc](https://lib.rs/crates/fastcdc)  is distributed under the terms of the  MIT license\n\n[Asuran Chunker](https://lib.rs/crates/asuran-chunker) is distributed under the terms of the [BSD 2 Clause + Patent License](https://gitlab.com/asuran-rs/asuran/blob/381097b04ffb3c329d0fcdaa0965a8bd40592f2d/LICENSE).\n\n\n\n\n","readmeFilename":"README.md"}