Skip to content

Non-self-closing tags without text get removed #4

@patkruk

Description

@patkruk

The library removes non-self-closing tags without text, such as an iframe.

For example:

* string: <div class="media-pull-center media-width-full"><div class="embed-responsive embed-responsive-16by9"><iframe src="https://link.brightcove.com/services/player/" frameborder="0" allowfullscreen></iframe></div><div class="content-item__credit pull-right">Credit</div><div class="content-item__caption clearfix">Caption</div></div>
* length: 500
* result: <div class="media-pull-center media-width-full"><div class="content-item__credit pull-right">Credit</div><div class="content-item__caption clearfix">Caption</div></div>
* desired result: <div class="media-pull-center media-width-full"><div class="embed-responsive embed-responsive-16by9"><iframe src="https://link.brightcove.com/services/player/" frameborder="0" allowfullscreen></iframe></div><div class="content-item__credit pull-right">Credit</div><div class="content-item__caption clearfix">Caption</div></div>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions