cached_lottie_network 0.0.2 copy "cached_lottie_network: ^0.0.2" to clipboard
cached_lottie_network: ^0.0.2 copied to clipboard

A Flutter package for caching and displaying Lottie animations from network URLs with offline support and secure local storage.

Cached Lottie Network #

A Flutter package that helps you cache and display Lottie animations from network URLs with offline support. This package automatically saves Lottie animations to local storage, allowing your app to display animations even when offline.

Features #

  • ✨ Cache Lottie animations for offline use
  • 🔒 Secure local storage using flutter_secure_storage
  • 🌐 Network connectivity handling
  • ⚡ Fast loading from cache
  • 🎨 Built-in loading widget support

Installation #

Add this to your package's pubspec.yaml file:

dependencies:
  cached_lottie_network: ^0.0.2

Usage #

Basic Usage #

CacheLottieNetwork(
  lottieUrl: "https://example.com/animation.json",
  cacheKey: "unique_key_1",
)

Important Notes #

  1. Always use unique cache keys for different animations
  2. The animation will be automatically cached when:
    • The device has internet connection and downloads the animation
    • Once cached, it will be available offline
  3. The package handles:
    • Automatic caching of animations
    • Network connectivity checks
    • Secure storage of animation data

Dependencies #

  • connectivity_plus: ^6.1.2
  • dio: ^5.2.1+1
  • flutter_secure_storage: ^9.2.4
  • lottie: ^3.1.3

Contributing #

Feel free to contribute to this project by creating issues or submitting pull requests.

License #

This project is licensed under the MIT License - see the LICENSE file for details.

1
likes
140
points
19
downloads

Publisher

unverified uploader

Weekly Downloads

A Flutter package for caching and displaying Lottie animations from network URLs with offline support and secure local storage.

Repository (GitHub)
View/report issues

Documentation

API reference

License

GPL-3.0 (license)

Dependencies

connectivity_plus, dio, flutter, flutter_secure_storage, lottie

More

Packages that depend on cached_lottie_network