React JS

  1. First, install Lottielab's Lottie player from npm by running:

npm install --save @lottielab/lottie-player
  1. Import the React component:

import Lottie from '@lottielab/lottie-player/react';
  1. Use the Lottie React component to display your Lottie using your Livelink:

<Lottie src="https://cdn.lottielab.com/insertyourlottieanimationlink.json" autoplay />

Check out the documentation for Lottielab's Lottie player, where you can learn how to control various aspects of the player, such as playback speed, loop, and control it programatically.

Last updated