Temzasse / react-modal-sheet

Flexible bottom sheet component built with Framer Motion to provide buttery smooth UX while keeping accessibility in mind 🪐

Home Page:https://temzasse.github.io/react-modal-sheet/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

framer-motion is not tree-shaking

kestevez-rv opened this issue · comments

Could you please make use of framer-motion in such a way to provide tree-shake to reduce the bundle size?

Hi @kestevez-rv 👋🏻

How could that be done? This library is using quite a lot of framer-motion features and based on the docs I would have to include the domMax feature set which wouldn't give any reduction in bundle size, right?

commented

@Temzasse From my understanding you will have to load domMax but it will be loaded async so the initial bundle size will be smaller (As far as I understood it), but then it will load the rest in a different chunk.

commented

Unfortunately the 100kb framer-motion adds is a real deal breaker for us, great lib nonetheless