Skip to content

Can I access the contents of HTML elements without it being trimmed? #160

Discussion options

You must be logged in to vote

hey,
i think i would probably do something like this:

@Language("HTML")
val someMarkupWithLinks: String = """
            <div class="foo">
                <ul>
                    <li>
                        <span>abc</span>
                        <a href="http://www.valid.com">a valid link</a>
                    </li>
                    <li>
                        <span>def</span>
                        <a href="http://www . invalid . com">an invalid link</a>
                    </li>
                    <li>
                        <span>ghi</span>
                        <a href="http://valid.com/rocks">another valid link</a>
                    </li>
                    <li>

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by christian-draeger
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
question Further information is requested
2 participants
Converted from issue

This discussion was converted from issue #128 on June 29, 2021 21:04.