Skip to content

Split react icons #2533

Description

@karelhala

Currently if any icon is imported from @patternlfy/react-icons package, it will bundle all icons into your final bundle. This happens even if you reference the icon directly @patternlfy/react-icons/dist/esm/icons/ad-icon.

It would be nice if there would be something similiar to what lodash is doing by creating different files in root folder of their package. Another great example can be material UI icons [1]. You can import single icon or entire package.

I think that the build might be slightly broken in a way that if you import anything it will automatically include all things from the package so some investigation on this matter would be really appreciated.

[1] https://www.npmjs.com/package/@material/react-material-icon

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions