github pmndrs/react-spring v10.1.2

latest release: v11.0.0-beta.0
6 hours ago

Bug Fixes

  • core: PickAnimated now infers all animated keys when a partial from is provided. Previously a from prop collapsed the result type to just the from shape, dropping to keys, forward props, and the other transition phases — so useSpring({ width: 100, height: 100, from: { width: 0 } }) made styles.height a compile error even though height animates at runtime. It now merges from with the to, forward, and transition-phase values. (#2545)
  • core: The SpringValue-level onChange now receives an AnimationResult ({ value, finished: false, cancelled: false }) instead of the raw value, so result.value is no longer undefined mid-animation. This matches onStart/onRest and the Controller-level onChange. The internal change event the animated tree subscribes to still emits the raw value. (#2548)
  • animated: Fixed a cannot add a new property crash when wrapping non-extensible React Native host components. On Hermes, host components like View, Text, and Image become non-extensible after their first render, breaking the wrapper cache. createHost now attempts the direct write first (fast path, unchanged for extensible components) and falls back to a module-level WeakMap when the write is rejected. (#2535)

Performance

  • shared: Improved string interpolation performance with large amounts of data by caching output number parsing in createStringInterpolator. (#2547)

Full Changelog: v10.1.1...v10.1.2

Don't miss a new react-spring release

NewReleases is sending notifications on new releases.