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

Function sync

ui/src/lib/router.svelte.ts:202–205  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

200let current = $state<RouterLocation>(initial);
201
202function sync(): void {
203 const next = parseHash(location.hash);
204 if (next.raw !== current.raw) current = next;
205}
206
207if (typeof window !== 'undefined') {
208 window.addEventListener('hashchange', sync);

Callers

nothing calls this directly

Calls 1

parseHashFunction · 0.85

Tested by

no test coverage detected