MCPcopy Create free account
hub / github.com/editablejs/editable / handleRouteChangeStart

Function handleRouteChangeStart

apps/docs/src/hooks/usePendingRoute.ts:11–19  ·  view source on GitHub ↗
(url: string)

Source from the content-addressed store, hash-verified

9 let routeTransitionTimer: any = null
10
11 const handleRouteChangeStart = (url: string) => {
12 clearTimeout(routeTransitionTimer)
13 routeTransitionTimer = setTimeout(() => {
14 if (currentRoute.current !== url) {
15 currentRoute.current = url
16 setPendingRoute(url)
17 }
18 }, 100)
19 }
20 const handleRouteChangeComplete = () => {
21 setPendingRoute(null)
22 clearTimeout(routeTransitionTimer)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…