Packages

framer-motion

14.7.1 · 27 Oct 2026MIT45.3M / weekRepositoryHomepagenpmAtom feed

Upgrading framer-motion from 1.16.18 to 2.0.0

1 release in betweenevery note read

Other targets from 1.16.18Latest14.7.1
5
changes to make
0
advisories fixed
5
new
1
fix

Before you upgrade

Tick each one off as you go
  • breaking2.0.0
  • breaking2.0.0
  • breaking2.0.0
  • breaking2.0.0
  • breaking2.0.0

Release by release

  1. 2.0.0

    15 Jul 20205 new · 1 fix
    • new

      layout prop for automatic layout animations.

    • new

      AnimateSharedLayout and layoutId for shared layout animations.

    • new

      onMeasureDragConstraints prop that fires when dragConstraints are measured.

    • new

      useIsPresent, a read-only version of usePresence.

    • new

      Allow dragConstraints to be a ref that is smaller than the draggable element.

    • fixed

      Removing a MotionValue from style now correctly unsets it from the element.

4 other lines we could not sort, mostly version bumps
  • Using Proxy to generate motion components. This saves ~0.5kb from the bundle size and ensures compatibility with all DOM elements and Web Components.

    2.0.0
  • x and y transform values won't change as a result of a drag gesture as this now works via layout projection.

    2.0.0
  • Drag events now report point as the pointer relative to the viewport, in line with other pointer events.

    2.0.0
  • Changed build process and using Terser for uglification. Reduces bundle size by ~1.2kb. (@stokesman in #596)

    2.0.0