Skip to content

svelte:element buggy behaviour with class:foo #7521

@AlbertMarashi

Description

@AlbertMarashi

Describe the bug

Svelte is having buggy behavior with the new svelte:element. The advanced classes (class:foo) do not properly work with props for some reason. I haven't narrowed down why, but I have created a REPL below.

Reproduction

https://svelte.dev/repl/c74f48f8e55445c9b02734145bf78391?version=3.48.0

Workarounds

not using class:foo, and switching to class="{foo ? 'foo' : ''}" (at the cost of missing unused classes)

System Info

N/A

Severity

annoyance

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