Skip to content

[Icons] Alias for icons #1767

Closed
Closed
@Xbirdfr

Description

@Xbirdfr

Hi !

I love the icon initiative, a very great ressource !

i'm comming with an idea, a thing that actually I use a lot in my custom projects:

an alias system for icons
Ex:

# config/packages/ux_icons.yaml
ux_icons:
    alias:
      - "home": "material-symbols:home"
# templates/base.html.twig
...
<a href="#">{{ ux_icon('home') }} Homepage </a>
...

this will ensure consistency of the icon throughout the project, and to be able to easily change / update it in one go

Or maybe a way to create a custom twig extension extending ux_icons already exist ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions