Skip to content

[Icons]: HTML syntax: Closing the tag with </twig:ux:icon> breaks it #2796

Closed as not planned
@ThomasLandauer

Description

@ThomasLandauer

When doing (as mentioned at https://symfony.com/bundles/ux-icons/current/index.html#twigcomponent )

<twig:ux:icon name="user-profile" class="w-4 h-4">🧸</twig:ux:icon>

I'm getting:

An exception has been thrown during the rendering of a template ("Unknown component "ux:icon". Did you mean this: "UX:Icon"?")

So it looks like only the self-closing syntax is allowed:

<twig:ux:icon name="user-profile" class="w-4 h-4" />

Versions:
Brandnew Symfony 7.3
symfony/ux-icons 2.25.0
symfony/ux-twig-component 2.25.2
twig/twig 3.21.1

P.S.: So the misleading hint for UX:Icon which you mention at #2307 (comment) is still there.

Metadata

Metadata

Assignees

No one assigned

    Labels

    IconsStatus: ReviewedHas been reviewed by a maintainerdocsImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions