react-spring-physics

Implements physics-based React animations using React Spring hooks and Popmotion utilities.

Updated Jun 30, 2026
One-click install
npx skills add https://github.com/ayofemiade/cleva --skill react-spring-physics-ayofemiade
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: react-spring-physics
Source: https://github.com/ayofemiade/cleva/tree/main/.claude/skills/react-spring-physics
Command: npx skills add https://github.com/ayofemiade/cleva --skill react-spring-physics-ayofemiade

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @react-spring/web, @react-spring/three, popmotion, @use-gesture/react, and includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve? Building natural, interruptible UI animations in React is difficult with duration-based CSS transitions, which feel artificial and lose momentum when interrupted by user input. This Skill provides spring-physics animation patterns that calculate motion from mass, tension, and friction for organic, gesture-responsive movement. ## Core Features & Use Cases - Spring Animation Patterns: Ready-to-use implementations of useSpring, useTrail, useTransition, useScroll, and useInView hooks for click, scroll, list, and viewport-triggered animations. - Physics Tuning Tools: A physics calculator script that computes damping ratios, critical friction, and settle times, plus a generator script that outputs boilerplate for seven common animation types. - Gesture and 3D Integration: Patterns for drag interactions with velocity preservation via @use-gesture/react and 3D scene animation via @react-spring/three. - Use Case: When building a draggable card interface, use the gesture pattern to track pointer movement with immediate updates, then release with preserved velocity so the card springs back naturally instead of snapping abruptly. ## Quick Start Ask the AI to create a click-triggered spring animation component using React Spring with a wobbly config preset.

Frequently Asked Questions about react-spring-physics

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a spring animation in React?▼

Use the useSpring hook from @react-spring/web with from and to values, then apply the returned springs to an animated component's style prop. Configure the feel with mass, tension, and friction, or use presets like config.wobbly and config.gentle.

React Spring vs Framer Motion for animations?▼

React Spring uses physics-based springs that calculate duration from mass, tension, and friction, producing interruptible motion that preserves velocity. Framer Motion uses a declarative variant and timeline approach better suited for choreographed multi-step sequences.

How do I animate list items entering and leaving in React?▼

Use the useTransition hook with from, enter, and leave style objects plus a keys function to identify items. It returns a render function that wraps each item in an animated.div with the transitioning styles applied.

Does React Spring work with React Three Fiber?▼

Yes, the @react-spring/three package provides animated wrappers for Three.js objects and materials. You can spring-animate properties like scale, position, and color on meshes inside a React Three Fiber Canvas.

Why does my React Spring animation feel too bouncy?▼

Excessive bounce means the spring is under-damped, so increase the friction value or use the config.stiff preset. You can also set clamp: true to prevent overshoot entirely, or compute critical damping as 2 times the square root of tension times mass.

How do I disable React Spring animations for testing?▼

Call Globals.assign({ skipAnimation: true }) from @react-spring/web in your test setup to make all animations resolve instantly. This also supports prefers-reduced-motion accessibility by checking the media query and toggling the global flag.