Skip to content

Content (inner text) should be placed in the correct order #7

@DavidVujic

Description

@DavidVujic

Describe the bug
Content is placed after any child elements of a html element. It should be able to use the position in the hiccup sequence.

To Reproduce
This test will fail:

def test_order_of_items() -> None:
    """Assert that items of different types are ordered as expected."""
    data = ["h1", "some", ["span.pys", "<py>"], "jokes"]

    assert render(data) == '<h1>some<span class="pys">&lt;py&gt;</span>jokes</h1>'

The rendered output is

<h1><span class="pys">&lt;py&gt;</span>somejokes</h1>

Expected behavior
It should be possible to specify the content to be before any child elements.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions