Skip to content

lottie-react-native 6.0 adds Fabric support on iOS and Android

updated

lottie-react-native has published v6.0.0, a release that brings Fabric support to both iOS and Android along with a set of fixes and breaking changes.

Example lottie-react-native animations: a map pin, a menu icon and a heart
Image: lottie-react-native/lottie-react-native (Apache-2.0)

Features

  • Fabric support for iOS and for Android
  • android-lottie upgraded to 6.0.0, then to 6.1.0
  • Native auto play implemented for Android and iOS

Bug fixes

  • Android: event dispatch logic refactored to fix a Fabric crash, support added for the upcoming 0.73, and resize mode fixed
  • iOS: fixes for a reset to the first frame on app resume, incorrectly calculated frames, a memory leak on deallocation, and jumping to the end frame; lottie-ios updated to 4.2.0 along with a build error fix
  • macOS: React Native macOS build fixed
  • Fabric build fixed on 0.68/0.69, plus an old arch implementation fix and other iOS-related fixes

Internal changes

The project has moved to a monorepo, its examples have been updated, and redundant logging has been removed.

Breaking changes

  • The Animated API is no longer used by default in the source code
  • Absolute style is no longer applied to the LottieView
  • Default aspect ratio styling has been removed
  • Default width and height are no longer applied
  • AnimatedLottieViewProps has been renamed to LottieViewProps

Known issues

On iOS with the new architecture turned on, the initial render does not always work as expected (issue #1043).

Contributors

The release credits @alfonsocj for the iOS New Architecture implementation and @AlexanderEggers for the Android implementation, and it lists six new contributors.

Source: github.com