loadLottie function

Loads the Lottie animation from the specified Lottie file.

Implementation

Future<LottieComposition> loadLottie(
  FutureOr<LottieBuilder> file,
) async {
  final loaded = await file;
  final composition = await loaded.lottie.load();

  return composition;
}