@boxxy/content-hash
v0.2.4
Published
Canonical JSON and the SHA-256 content hashes boxxy records
Readme
Canonical JSON and the SHA-256 content hashes boxxy records.
boxxy stores a content hash beside each recipe, rules version and snapshot. A value hashes the same whatever the order of its object keys.
Install
Install the package from npm with Bun:
bun add @boxxy/content-hashThe package runs on Bun 1.3 or newer.
Features
formatCanonicalJson, which writes a JSON value in the canonical form of RFC 8785.contentHash, the SHA-256 hex of a value's canonical JSON, as a brandedContentHash.hashBytes, the SHA-256 hex of a file's bytes.hashTree, the content hash of a folder's files, whatever order the caller walks them in.
Documentation
The first build spec lists the hashes boxxy records.
