MCPcopy Index your code
hub / github.com/21st-dev/1code / computeContentHash

Function computeContentHash

src/main/lib/git/cache/git-cache.ts:192–194  ·  view source on GitHub ↗
(content: string)

Source from the content-addressed store, hash-verified

190 * Compute content hash for cache invalidation.
191 */
192export function computeContentHash(content: string): string {
193 return createHash("sha256").update(content).digest("hex").slice(0, 16);
194}
195
196/**
197 * Estimate byte size of a JavaScript value.

Callers 3

chats.tsFile · 0.90
setStatusMethod · 0.85
setFileContentMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected