When building my application (that uses @tabler/icons-solidjs) with Vite I was expecting icons to be tree shaken to only include the ones imported. But ALL icons are being included in the build.
Example import:
import {
IconArrowNarrowRight,
IconTrendingDown,
IconTrendingUp,
} from "@tabler/icons-solidjs";
Running vite build results in all tabler icons being included, greatly bloating the application bundle.
I see there were related issues reported against Svelte integration., but none specific to the Solid integration.
Package
[ ] @tabler/icons
[ ] @tabler/icons-eps
[ ] @tabler/icons-pdf
[ ] @tabler/icons-png
[ ] @tabler/icons-webfont
[ ] @tabler/icons-sprite
[ ] @tabler/icons-preact
[ ] @tabler/icons-react
[ ] @tabler/icons-react-native
[X] @tabler/icons-solid
[ ] @tabler/icons-svelte
[ ] @tabler/icons-vue
[ ] Figma plugin
[ ] source/main
[ ] other/not relevant
Version
3.11.0
Browser
[ ] Chrome/Chromium
[ ] Firefox
[ ] Safari
[ ] Edge
[ ] iOS Safari
[ ] Opera
[X] Other/not relevant
Operating system
[ ] Windows
[ ] Linux
[X] macOS
[ ] ChromeOS
[ ] iOS
[ ] Android
[ ] Other/not relevant
Steps to reproduce
Add @tabler/icons-solidjs to package (pnpm add)
Import an icon and use it (e.g. import { IconTrendingUp } from "@tabler/icons-solidjs";
Run vite build (via pnpm run build)
Note that ALL tabler icons are processed and included in the build.
Checklist
[X] I have searched if someone has submitted a similar issue before and there weren't any. (Please make sure to also search closed issues, as this issue might already have been resolved.)
Description
When building my application (that uses
@tabler/icons-solidjs
) with Vite I was expecting icons to be tree shaken to only include the ones imported. But ALL icons are being included in the build.Example import:
Running
vite build
results in all tabler icons being included, greatly bloating the application bundle.I see there were related issues reported against Svelte integration., but none specific to the Solid integration.
Package
Version
3.11.0
Browser
Operating system
Steps to reproduce
@tabler/icons-solidjs
to package (pnpm add
)import { IconTrendingUp } from "@tabler/icons-solidjs";
vite build
(viapnpm run build
)Checklist