tremorlabs / tremor

React components to build charts and dashboards
https://tremor.so
Apache License 2.0
15.53k stars 450 forks source link

[Question]: Installation / peer deps #1037

Open afraser opened 3 weeks ago

afraser commented 3 weeks ago

I'm reading your installation guide and am confused as to why there are so many things to install that aren't listed among the other peer dependencies on package json.

Specifically these:

@headlessui/react
@headlessui/tailwindcss
@tailwindcss/forms
@remixicon/react

The documentation doesn't currently explain when/why these are required and I don't understand why they aren't simply bundled.

Somewhat related: Bundlephobia is showing me a confusing breakdown of the bundle here:

CleanShot 2024-05-08 at 144310 png

  1. the bundle is nearly a megabyte in size
  2. It's showing date-fns as being ~300kb when it's really about 75kb
  3. It's showing recharts as taking up ~300kb... this is actually plausible assuming it was tree-shaken on your end.