{"_id":"@chainsafe/hashtree","_rev":"6-71aded89a84b18b699432178969a0cd6","name":"@chainsafe/hashtree","dist-tags":{"latest":"1.0.2"},"versions":{"1.0.0":{"name":"@chainsafe/hashtree","version":"1.0.0","author":{"name":"ChainSafe.io"},"license":"MIT","_id":"@chainsafe/hashtree@1.0.0","maintainers":[{"name":"wemeetagain","email":"caymannava@gmail.com"},{"name":"mpetrunic","email":"marin.petrunic@gmail.com"}],"contributors":[{"name":"Cayman Nava","email":"caymannava@gmail.com"},{"name":"Matthew Keil","email":"me@matthewkeil.com"}],"homepage":"https://github.com/ChainSafe/hashtree-js#readme","bugs":{"url":"https://github.com/ChainSafe/hashtree-js/issues"},"dist":{"shasum":"529439fb07299758ca5bbe69a00d1dc4ad83a949","tarball":"https://registry.npmjs.org/@chainsafe/hashtree/-/hashtree-1.0.0.tgz","fileCount":46,"integrity":"sha512-qft0MZiLl5jbe8omZaSp1vQ2YCO9qCb262+5qD1vsgN6l1ga3ZFKLyNI6xvwbhC7ZnzZd46vr+p+KvdUIgruOw==","signatures":[{"sig":"MEYCIQCQLJqi/0Nvw+EcJEj4VMg0RWyTiYLhuGkfAFLijvpptAIhANMBrhnfySktufBrP/4ZMd9sdQUsYvO6poUoUP30WykR","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@chainsafe%2fhashtree@1.0.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":403397},"main":"index.js","napi":{"name":"hashtree","triples":{"defaults":false,"additional":["aarch64-unknown-linux-gnu"]}},"types":"index.d.ts","engines":{"node":">= 18"},"gitHead":"d0793b42a345bd42ef118f3baca98f7bf4768c71","scripts":{"test":"jest","build":"napi build --platform --release","clean":"rm -rf ./target ./hashtree/target","version":"napi version","artifacts":"napi artifacts","universal":"napi universal","build:debug":"napi build --platform","prepublishOnly":"napi prepublish -t npm","check-package-versions":"ts-node ./scripts/checkPackageVersions"},"_npmUser":{"name":"wemeetagain","email":"caymannava@gmail.com"},"repository":{"url":"git+https://github.com/ChainSafe/hashtree-js.git","type":"git"},"_npmVersion":"10.7.0","description":"Simple NAPI wrapper around https://github.com/prysmaticlabs/hashtree","directories":{},"_nodeVersion":"20.14.0","_hasShrinkwrap":false,"devDependencies":{"jest":"^29.1.2","eslint":"^8.55.0","ts-jest":"^29.1.2","ts-node":"^10.9.2","prettier":"^3.1.1","typescript":"^5.2.2","@types/jest":"^29.1.2","@types/node":"^20.13.0","@napi-rs/cli":"^2.18.0","eslint-plugin-jest":"^28.5.0","eslint-plugin-node":"^11.1.0","eslint-plugin-import":"^2.29.0","eslint-plugin-prettier":"^5.0.1","@typescript-eslint/parser":"^6.14.0","@typescript-eslint/eslint-plugin":"^6.14.0"},"peerDependencies":{"@chainsafe/hashtree-darwin-arm64":"1.0.0","@chainsafe/hashtree-linux-x64-gnu":"1.0.0","@chainsafe/hashtree-linux-arm64-gnu":"1.0.0"},"optionalDependencies":{"@chainsafe/hashtree-linux-arm64-gnu":"1.0.0"},"_npmOperationalInternal":{"tmp":"tmp/hashtree_1.0.0_1717780849589_0.7976789752241327","host":"s3://npm-registry-packages"}},"1.0.1":{"name":"@chainsafe/hashtree","version":"1.0.1","keywords":["hash","hashtree","merkle","NAPI","N-API","sha256"],"author":{"name":"ChainSafe.io"},"license":"MIT","_id":"@chainsafe/hashtree@1.0.1","contributors":[{"name":"Cayman Nava","email":"caymannava@gmail.com"},{"name":"Matthew Keil","email":"me@matthewkeil.com"}],"homepage":"https://github.com/ChainSafe/hashtree-js#readme","bugs":{"url":"https://github.com/ChainSafe/hashtree-js/issues"},"dist":{"shasum":"587666a261e1da6a37904095ce875fddc53c7c89","tarball":"https://registry.npmjs.org/@chainsafe/hashtree/-/hashtree-1.0.1.tgz","fileCount":5,"integrity":"sha512-bleu9FjqBeR/l6W1u2Lz+HsS0b0LLJX2eUt3hOPBN7VqOhidx8wzkVh2S7YurS+iTQtfdK4K5QU9tcTGNrGwDg==","signatures":[{"sig":"MEUCIHF7+WnGlDwVl3OBKRqr66q7nXFAjNLaquF1syRMa7V2AiEA8JE1CKuAwq6/MefMpqeH0AT0h+dDCMrDbvibvfGCJZg=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@chainsafe%2fhashtree@1.0.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":13515},"main":"index.js","napi":{"name":"hashtree","triples":{"defaults":false,"additional":["aarch64-apple-darwin","x86_64-unknown-linux-gnu","aarch64-unknown-linux-gnu"]}},"types":"index.d.ts","engines":{"node":">= 18"},"gitHead":"d48291ad8a7679fa6ced6a0dffea53fba459779b","scripts":{"test":"jest","build":"napi build --platform --release","clean":"rm -rf ./target ./hashtree/target","version":"napi version","artifacts":"napi artifacts","universal":"napi universal","build:debug":"napi build --platform","prepublishOnly":"napi prepublish -t npm","check-package-versions":"ts-node ./scripts/checkPackageVersions"},"_npmUser":{"name":"wemeetagain","email":"caymannava@gmail.com"},"repository":{"url":"git+https://github.com/ChainSafe/hashtree-js.git","type":"git"},"_npmVersion":"10.7.0","description":"Simple NAPI wrapper around https://github.com/prysmaticlabs/hashtree","directories":{},"_nodeVersion":"20.15.0","_hasShrinkwrap":false,"devDependencies":{"jest":"^29.1.2","eslint":"^8.55.0","ts-jest":"^29.1.2","ts-node":"^10.9.2","prettier":"^3.1.1","typescript":"^5.2.2","@types/jest":"^29.1.2","@types/node":"^20.13.0","@napi-rs/cli":"^2.18.0","eslint-plugin-jest":"^28.5.0","eslint-plugin-node":"^11.1.0","eslint-plugin-import":"^2.29.0","eslint-plugin-prettier":"^5.0.1","@typescript-eslint/parser":"^6.14.0","@typescript-eslint/eslint-plugin":"^6.14.0"},"optionalDependencies":{"@chainsafe/hashtree-darwin-arm64":"1.0.1","@chainsafe/hashtree-linux-x64-gnu":"1.0.1","@chainsafe/hashtree-linux-arm64-gnu":"1.0.1"},"_npmOperationalInternal":{"tmp":"tmp/hashtree_1.0.1_1719422245440_0.20309953715059437","host":"s3://npm-registry-packages"}},"1.0.2":{"name":"@chainsafe/hashtree","version":"1.0.2","keywords":["hash","hashtree","merkle","NAPI","N-API","sha256"],"author":{"name":"ChainSafe.io"},"license":"MIT","_id":"@chainsafe/hashtree@1.0.2","maintainers":[{"name":"wemeetagain","email":"caymannava@gmail.com"},{"name":"mpetrunic","email":"marin.petrunic@gmail.com"}],"contributors":[{"name":"Cayman Nava","email":"caymannava@gmail.com"},{"name":"Matthew Keil","email":"me@matthewkeil.com"}],"homepage":"https://github.com/ChainSafe/hashtree-js#readme","bugs":{"url":"https://github.com/ChainSafe/hashtree-js/issues"},"dist":{"shasum":"2a16b49e491bef9e5760cd1010363cb3d1351fb8","tarball":"https://registry.npmjs.org/@chainsafe/hashtree/-/hashtree-1.0.2.tgz","fileCount":5,"integrity":"sha512-OaWjsZ6S/GaT2RvaqdpsF5Mux8qQOE2KbitX2yHmQJZNUZkdh7C3N4PA5LsvewqX+z8Nkv8mr1uSe0LSrHGiQw==","signatures":[{"sig":"MEQCIFU6UE1Hh0VWX+e9Wkk7NIvueDGH/NAtzbYHbcghlX5uAiBz0WnIivFiNR/gSJNZV8NsPkFGni4Z6Xp8Fv/qjdqRrg==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@chainsafe%2fhashtree@1.0.2","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":25465},"main":"index.js","napi":{"targets":["aarch64-apple-darwin","x86_64-unknown-linux-gnu","aarch64-unknown-linux-gnu","x86_64-unknown-linux-musl","aarch64-unknown-linux-musl","x86_64-pc-windows-msvc"],"binaryName":"hashtree"},"types":"index.d.ts","engines":{"node":">= 18"},"gitHead":"8cf0ead9d8940938a3d82c91f3e1558c7eca3ea3","scripts":{"lint":"oxlint .","test":"jest","build":"napi build --platform --release","clean":"rm -rf ./target ./hashtree/target","artifacts":"napi artifacts","build:debug":"napi build --platform","prepublishOnly":"napi prepublish -t npm","check-package-versions":"ts-node ./scripts/checkPackageVersions"},"_npmUser":{"name":"wemeetagain","email":"caymannava@gmail.com"},"repository":{"url":"git+https://github.com/ChainSafe/hashtree-js.git","type":"git"},"_npmVersion":"10.9.3","description":"Simple NAPI wrapper around https://github.com/prysmaticlabs/hashtree","directories":{},"_nodeVersion":"22.18.0","_hasShrinkwrap":false,"packageManager":"yarn@4.9.2","devDependencies":{"jest":"^29.1.2","oxlint":"^1.9.0","ts-jest":"^29.1.2","ts-node":"^10.9.2","typescript":"^5.2.2","@types/jest":"^29.1.2","@types/node":"^20.13.0","@napi-rs/cli":"^3.1.2"},"optionalDependencies":{"@chainsafe/hashtree-darwin-arm64":"1.0.2","@chainsafe/hashtree-linux-x64-gnu":"1.0.2","@chainsafe/hashtree-linux-x64-musl":"1.0.2","@chainsafe/hashtree-win32-x64-msvc":"1.0.2","@chainsafe/hashtree-linux-arm64-gnu":"1.0.2","@chainsafe/hashtree-linux-arm64-musl":"1.0.2"},"_npmOperationalInternal":{"tmp":"tmp/hashtree_1.0.2_1755008534179_0.2868208946680628","host":"s3://npm-registry-packages-npm-production"}}},"time":{"created":"2024-06-07T17:20:49.479Z","modified":"2026-04-21T09:51:50.866Z","1.0.0":"2024-06-07T17:20:49.836Z","1.0.1":"2024-06-26T17:17:25.617Z","1.0.2":"2025-08-12T14:22:14.348Z"},"bugs":{"url":"https://github.com/ChainSafe/hashtree-js/issues"},"author":{"name":"ChainSafe.io"},"license":"MIT","homepage":"https://github.com/ChainSafe/hashtree-js#readme","keywords":["hash","hashtree","merkle","NAPI","N-API","sha256"],"repository":{"url":"git+https://github.com/ChainSafe/hashtree-js.git","type":"git"},"description":"Simple NAPI wrapper around https://github.com/prysmaticlabs/hashtree","contributors":[{"name":"Cayman Nava","email":"caymannava@gmail.com"},{"name":"Matthew Keil","email":"me@matthewkeil.com"}],"maintainers":[{"email":"caymannava@gmail.com","name":"wemeetagain"},{"email":"me@matthewkeil.com","name":"matthewkeil"}],"readme":"# @chainsafe/hashtree\n\nSimple NAPI wrapper around https://github.com/prysmaticlabs/hashtree\n\n\n## Example\n\n```ts\nimport {hash, hashInto} from \"@chainsafe/hashtree\"\n\n// input is a Uint8Array of concatenated left-right tuples\nconst input: Uint8Array = Buffer.concat([\n  Buffer.alloc(32), Buffer.alloc(32),\n  Buffer.alloc(32, 1), Buffer.alloc(32, 1),\n])\n\n// output will be a Uint8Array of concatenated output hashes\nconst output = hash(input)\n\n// for example, when compared to node:crypto usage:\nimport {createHash} from \"node:crypto\"\n\nBuffer.compare(\n  createHash(\"sha256\").update(input.slice(0, 64)).digest(),\n  output.slice(0, 32)\n) === 0\nBuffer.compare(\n  createHash(\"sha256\").update(input.slice(64)).digest(),\n  output.slice(32)\n) === 0\n\n// alternative interface with preallocated output\nconst output2 = new Uint8Array(input.length / 2)\nhashInto(input, output2)\n```\n\n## License\n\nMIT","readmeFilename":"README.md"}