How to use Lottie-Interactive

Lottie-interactive is a custom web element allowing you to load and interact with Lottie animations in the easiest manner possible.

Getting started

(Video explanation available at the bottom of the page)
Method 1: Using the pre-built JS file
After downloading lottie-interactive.js from the repository you can move it in to your project where you store your other Javascript libraries and include it in your HTML like so:
Method 2: Using npm
If you prefer to use npm, run the following command inside your project:

Using Lottie-interactive

If you used npm, don't forget to import the library:
And then use in your page by declaring a 'lottie-interactive' element.
It's a simple as that! Lottie-interactive will load and play your Lottie animation depending on the interaction type you use as attribute. If you want to read more on the different interactions possible, they are all described on the Github repository.