WE

Web

@react-spring/web

`react-dom` support

React Native Libraries
animated
animation
hooks
motion
react
react-native
spring
typescript
velocity
@react-spring/web
Stars
29k
Weekly
4.7M
Open issues
75
Bundle
~25 kB

Installation

npm install @react-spring/web

Code example

import { useSpring, animated } from "@react-spring/web";

export function Example() {
  const styles = useSpring({ from: { opacity: 0 }, to: { opacity: 1 } });
  return <animated.div style={styles}>Hello</animated.div>;
}

Pros & cons

Pros

  • Actively maintained by Paul Henschel
  • 4.7M weekly downloads. Battle tested
  • First-class TypeScript definitions
  • MIT licensed

Considerations

  • Adds roughly ~25 kB to your bundle
  • Needs client-only rendering in SSR frameworks
  • 75 open issues on GitHub

FAQs

Alternatives & similar libraries