Pure-JavaScript hash functions for generating deterministic element IDs.
These functions use FNV-1a internally and produce hex strings whose
lengths match SHA-1 (40 chars) and MD5 (32 chars) for compatibility
with Wikidot's ID generation patterns. Cryptographic security is not
required; the hashes only need to be deterministic and well-distributed.
node:crypto is intentionally avoided because bunup's ESM build
injects createRequire from node:module, which is incompatible
with browser environments.
Pure-JavaScript hash functions for generating deterministic element IDs.
These functions use FNV-1a internally and produce hex strings whose lengths match SHA-1 (40 chars) and MD5 (32 chars) for compatibility with Wikidot's ID generation patterns. Cryptographic security is not required; the hashes only need to be deterministic and well-distributed.
node:cryptois intentionally avoided becausebunup's ESM build injectscreateRequirefromnode:module, which is incompatible with browser environments.