Skip to content

Snippet block not including multiple elements #113

@blndab

Description

@blndab

I am trying to display the code snippet for a button with an icon, but the snippet doesn't display properly.
These are the lines in my .jade file:

if button.hasIcon
    a.snippet(class="#{button.className}" href='#')
        i(class="fas #{button.iconName}")
        =button.buttonName

And this is how it is displayed:

<a href="#" class="btn btn-secondary btn-small">Filter</a>

It should be like this though:

<a href="#" class="btn btn-secondary btn-small">
    <i class="fas fa-filter">
        ::before
    </i>
    "Filter"
</a>

Can anyone help please?

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