design-infraGitHub
Report a problem or share feedback← Catalog

AnimatePresence modes

curatedfree

motion/animate-presence-modes

An example of the three AnimatePresence modes (sync, wait, and popLayout) demonstrating how elements enter and exit the DOM with Motion for React.

state — subtlerecipeExperimentalRefinedPlayful
$pnpm add motion # then adapt the free source from https://motion.dev/examples/react-animate-presence-modes

npm deps: motion

Our notes

AnimatePresence `mode` (sync / wait / popLayout): how to swap one view for another — tab panels, carousel slides, step wizards — without overlap jank. Free example (motion is MIT); copy and adapt the source from the example page.
AnimatePresence modes preview
Source
Motion (motion.dev)
Kind
transition
Categories
transition, input
Use as
recipe — technique you apply to your own markup
Applies to
modaltabscarousel
Motion
on state · subtle · motion · low cost
Tags
motion, AnimatePresence, animate, whileTap
Licence
motion / motion/react / motion-v are MIT. Motion+ (premium components, example source, AI Kit pro tools) is paid — one-time Personal licence or per-seat Business.
Live demo
motion.dev
Docs
motion.dev