flotter 0.1.0 copy "flotter: ^0.1.0" to clipboard
flotter: ^0.1.0 copied to clipboard

outdated

Use Lottie animations on iOS.

flotter #

Use Lottie animations on iOS.

Important note #

First of all, you must add this to your info.plist file in your iOS project in order to enable the animation views to work correctly:

<key>io.flutter.embedded_views_preview</key>
<true/>

Getting started #

This plugin allows the use of the LOTAnimationView on iOS using Flutter's FlotterAnimation class.

To add an animation to your application,you must first create a FotterAnimationController. It will hold your animation's informations, such as the path of the json file in your assets containing the animation, the name given to the animation, and a few other parameters:

var controller = FlotterAnimationController(
    animationFilePath,
    name,
    isLoop, // false by default
    autoReverse, // false by default
);

Then, you simply add the controller to an animation view like this:

var animation = FlotterAnimation(controller);

Methods #

Now, you can control your animation using:

play() #

controller.start()

pause() #

controller.pause()

reverse() #

controller.reverse()

stop() #

controller.stop()

About #

This project is a starting point for a Flutter plug-in package, a specialized package that includes platform-specific implementation code for Android and/or iOS.

For help getting started with Flutter, view our online documentation, which offers tutorials, samples, guidance on mobile development, and a full API reference.

1
likes
0
pub points
0%
popularity

Publisher

unverified uploader

Use Lottie animations on iOS.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter

More

Packages that depend on flotter