Skip to content

Some significant whitespace is inserted in "xmlWhitespaceSensitivity: ignore" mode  #138

Closed
@sbidoul

Description

@sbidoul

Assume the following xml file:

<test>

   <field name="report_name">event_third_party.template_event_third_party_summary</field>

   <field name="report_file">event_third_party.template_event_third_party_summary</field>

</test>

In xmlWhitespaceSensitivity: ignore mode, signficant whitespace is sometimes inserted to cut long lines, so we get:

<test>
    <field name="report_name">
        event_third_party.template_event_third_party_summary
    </field>
    <field name="report_file">
        event_third_party.template_event_third_party_summary
    </field>
</test>

For our application, the inserted space in field elements is significant.

In strict mode the issue does not occur, but then most automatic indenting is disabled.

My feeling is that, in ignore mode, the text content of an element should never be modified as soon as there is a non-whitespace character in it.

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