MCPcopy Create free account
hub / github.com/DavidHDev/react-bits / ensureLoop

Function ensureLoop

src/ts-default/Animations/GhostCursor/GhostCursor.tsx:426–431  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

424 };
425
426 const ensureLoop = () => {
427 if (!runningRef.current) {
428 runningRef.current = true;
429 rafRef.current = requestAnimationFrame(animate);
430 }
431 };
432
433 const onPointerMove = (e: PointerEvent) => {
434 const rect = parent.getBoundingClientRect();

Callers 4

onPointerMoveFunction · 0.70
onPointerEnterFunction · 0.70
onPointerLeaveFunction · 0.70
GhostCursorFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected