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

Function handleAnimation

src/content/Components/PixelCard/PixelCard.jsx:196–199  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

194 };
195
196 const handleAnimation = name => {
197 cancelAnimationFrame(animationRef.current);
198 animationRef.current = requestAnimationFrame(() => doAnimate(name));
199 };
200
201 const onMouseEnter = () => handleAnimation('appear');
202 const onMouseLeave = () => handleAnimation('disappear');

Callers 4

onMouseEnterFunction · 0.70
onMouseLeaveFunction · 0.70
onFocusFunction · 0.70
onBlurFunction · 0.70

Calls 1

doAnimateFunction · 0.70

Tested by

no test coverage detected