Skip to content

Barrel imports in lucide-solid is slowing down the performance of Tanstack Start with Solid #6344

@Ashvith10

Description

@Ashvith10

Which project does this relate to?

Start

Describe the bug

Context: lucide-solid is bundled in Tanstack Start's Solid template.

During HMR, Vite seems to load almost all of the icons in Lucide Solid because of barrel imports. This slows down the webpage a lot during development (not tested on production build).

Your Example Website or App

https://tanstack.com/start/latest/docs/framework/solid/quick-start

Steps to Reproduce the Bug or Issue

(Ps. Stackblitz took too long, so I am redirecting to the Tanstack Start "Quick Start" docs for Solid)

  1. Create a new Tanstack Start project:
npm create @tanstack/start@latest my-app -- --framework solid --deployment nitro --toolchain eslint --tailwind
  1. Start dev server
  2. Open browser and access the developer tools
  3. Go to localhost:3000
  4. Inspect the "Network" tab for request flood

Expected behavior

The default behaviour is that tree-shaking should work as expected.

Screenshots or Videos

-

Platform

  • Router / Start Version: 1.133.21
  • OS: Linux
  • Browser: Firefox
  • Browser Version: 146.0-2
  • Bundler: vite
  • Bundler Version: 7.1.7

Additional context

Please check out the discussions at lucide-icons/lucide/issues/1944 .

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions