MCPcopy Create free account
hub / github.com/codag-megalith/codag-visualizer / getFilePrefix

Method getFilePrefix

frontend/src/cache.ts:289–291  ·  view source on GitHub ↗

* Generate stable file prefix (6 chars) for node ID namespacing

(filePath: string)

Source from the content-addressed store, hash-verified

287 * Generate stable file prefix (6 chars) for node ID namespacing
288 */
289 getFilePrefix(filePath: string): string {
290 return crypto.createHash('md5').update(filePath).digest('hex').substring(0, 6);
291 }
292
293 /**
294 * Hash content (raw)

Callers

nothing calls this directly

Calls 1

updateMethod · 0.45

Tested by

no test coverage detected