Lottie Composition Result
A LottieCompositionResult subclass is returned from rememberLottieComposition. It can be completed with a result or exception only one time.
This class implements State
val compositionResult = rememberLottieComposition(...)
// Or
val composition by rememberLottieComposition(...)
Use the former if you need to explicitly differentiate between loading and error states or if you need to call await or awaitOrNull in a coroutine such as androidx.compose.runtime.LaunchedEffect.
See also
Functions
Properties
Extensions
awaitOrNull
Link copied to clipboard
Like LottieCompositionResult.await but returns null instead of throwing an exception if the animation fails to load.