Helper method that defines the lord-icon custom element with pre-made triggers and a player factory.
lord-icon
This method defines the following triggers:
Example of tag definition with the default setup:
import lottie from 'lottie-web';import { defineElement } from '@lordicon/element';defineElement(lottie.loadAnimation); Copy
import lottie from 'lottie-web';import { defineElement } from '@lordicon/element';defineElement(lottie.loadAnimation);
Basic usage from markup which is possible after tag definition:
<lord-icon trigger="hover" src="/icons/confetti.json"></lord-icon> Copy
<lord-icon trigger="hover" src="/icons/confetti.json"></lord-icon>
Use loadAnimation from the lottie-web package.
loadAnimation
lottie-web
Helper method that defines the
lord-icon
custom element with pre-made triggers and a player factory.This method defines the following triggers:
Example of tag definition with the default setup:
Basic usage from markup which is possible after tag definition: