react-lottie icon indicating copy to clipboard operation
react-lottie copied to clipboard

Bundle size of Lottie is very big

Open eyaleizenberg opened this issue 5 years ago • 5 comments

Screen Shot 2019-05-06 at 13 47 04

As you can see, the bundle size for react-lottie is very big. Any workarounds?

eyaleizenberg avatar May 06 '19 10:05 eyaleizenberg

Any news about this?

clieee avatar Sep 04 '19 23:09 clieee

Any news about this?

best bet is to use react lazy and suspense to auto code split

zyzski avatar Sep 19 '19 18:09 zyzski

It's huge! In https://github.com/crello/react-lottie we will try to do something with it in future versions. Mb lottie-light can be a problem solver. Or lottie lazy load option.

rndD avatar Dec 04 '19 10:12 rndD

I created a fork here https://github.com/alfonmga/react-lottie-light-ts that uses Lottie light version to achieve a smaller bundle size :)

You can add it to your project by running: yarn add @alfonmga/react-lottie-light-ts

alfonmga avatar Jan 16 '20 00:01 alfonmga

Here's an alternative that's ~2x smaller https://github.com/airbnb/lottie-web/issues/1184#issuecomment-703324484

kostia1st avatar Feb 07 '23 11:02 kostia1st