React Spring
Physics-based animation library for React
Natural feeling animations with spring physics. Cross-platform.
ReactAnimationPhysicsSpring
๐ฎ Playground
Use cases
- โขInteractive UIs
- โขData visualizations
- โขGames
Good for
- โPhysics-accurate animations
- โCross-platform apps
- โComplex gesture handling
Not good for
- โSimple CSS transitions
- โTimeline-based animations
Installation
$npm install @react-spring/web
Example
import { useSpring, animated } from "@react-spring/web"
export default function Demo() {
const styles = useSpring({
from: { opacity: 0 },
to: { opacity: 1 }
})
return <animated.div style={styles}>Hello</animated.div>
}Comparison
"More physics-accurate than Framer Motion, steeper learning curve but more control."
Trust Metrics
28.5K
GitHub Stars
1.5M
Weekly Downloads
Last Commit:last year
Used by
UberDiscordShopify
