All skills

Web & Frontend

Framer Motion

Overview

Framer Motion (now "Motion") is a production-ready animation library for React that turns declarative initial/animate props into smooth, GPU-accelerated transitions, gestures and layout animations.

How it works

jsx
<motion.div
  initial={{ opacity: 0 }}
  animate={{ opacity: 1 }}
/>

The flow

Step by step, from source to running.

  1. 1Wrap an element in motion.*
  2. 2Declare initial / animate states
  3. 3Motion interpolates each frame
  4. 4GPU-accelerated transforms render

Links

More in Web & Frontend