MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / encodeTrail

Function encodeTrail

ui/src/lib/trail-codec.ts:46–48  ·  view source on GitHub ↗
(hops: readonly TrailHop[])

Source from the content-addressed store, hash-verified

44}
45
46export function encodeTrail(hops: readonly TrailHop[]): string {
47 return hops.map((h) => DIR_TO_CHAR[h.dir] + encodeURIComponent(h.id)).join(',');
48}
49
50export function decodeTrail(encoded: string | null): TrailHop[] {
51 if (!encoded) return [];

Callers 4

encodedFunction · 0.90
hydrateFunction · 0.90
walkToFunction · 0.85

Calls 2

mapMethod · 0.80
joinMethod · 0.45

Tested by

no test coverage detected