react-spring-physics

Implements physics-based spring animations in React using React Spring and Popmotion libraries.

Updated Aug 26, 2026
One-click install
npx skills add https://github.com/aungpwint/presentation --skill react-spring-physics-aungpwint
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: react-spring-physics
Source: https://github.com/aungpwint/presentation/tree/main/.agents/skills/react-spring-physics
Command: npx skills add https://github.com/aungpwint/presentation --skill react-spring-physics-aungpwint

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve? Duration-based CSS animations feel artificial when interrupted and lose momentum on direction changes. This Skill provides patterns and references for building natural, physics-driven UI animations that respond to user input mid-motion. ## Core Features & Use Cases - Spring Animation Patterns: Ready-to-use implementations of useSpring, useTrail, useTransition, useScroll, and useInView hooks with tuned physics configs. - Physics Tuning Tools: A calculator script that computes damping ratios, critical friction, and settle times from mass/tension/friction parameters, plus a boilerplate generator for common animation types. - Gesture and 3D Integration: Patterns for drag interactions with @use-gesture, momentum preservation, and React Three Fiber animations via @react-spring/three. - Use Case: Build a draggable card that springs back with preserved velocity on release, or animate a list with staggered trail entrances that feel organic rather than timed. ## 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/to values and a physics config of mass, tension, and friction. Wrap your element with the animated component and pass the spring values to its style prop.

React Spring vs Framer Motion for animations?▼

React Spring calculates motion from physical properties like tension and friction, producing interruptible animations that preserve velocity. Framer Motion uses a variant-based declarative approach better suited for orchestrated layout animations.

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

Use the useTransition hook with from, enter, and leave style states plus a keys function to identify items. It returns a render function that maps each item to an animated element handling mount and unmount transitions.

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 mesh scale, position, and material properties inside a React Three Fiber Canvas.

Why does my React Spring animation feel too bouncy?▼

Excessive bounce means the damping ratio is below 1, so increase friction or use the config.stiff preset. Setting clamp to true in the config prevents overshoot entirely.

How do I disable React Spring animations for testing?▼

Call Globals.assign with skipAnimation set to true from @react-spring/web in your test setup. This makes all animations resolve instantly, and it also respects prefers-reduced-motion accessibility requirements.