alphapeter / fa-svelte

Font Awesome 5 for svelte.js
MIT License
71 stars 3 forks source link

Animated icons #20

Closed dgellow closed 3 years ago

dgellow commented 3 years ago

Hi @alphapeter,

Thanks for this library, it's quite handy. I understand that you don't want to support all features from Font Awesome icon sets, but have you considered supporting animated icons?

dgellow commented 3 years ago

Hmm, never mind, that's really simple to recreate using CSS animations:

    :global(.spinner) {
        animation: spinner-frames 3s infinite linear;
    }
    @keyframes spinner-frames {
        0% {
            transform: rotate(0deg);
        }
        100% {
            transform: rotate(360deg);
        }
    }

Maybe worth documenting in the README :)