Skip to content

CDATA looses spaces after formatting #293

Closed
@martinr92

Description

@martinr92

Description

The formatting removes tabs within the CDATA if the CDATA is a XML.

Example (original) XML:

<xml>
    <element><![CDATA[asdf]]></element>
    <element><![CDATA[<secondXml>
    <formattedNode>val</formattedNode>
</secondXml>]]></element>
</xml>

The XML above becomes to:

<xml>
    <element><![CDATA[asdf]]></element>
    <element><![CDATA[<secondXml>
<formattedNode>val</formattedNode>
</secondXml>]]></element>
</xml>

As you can see the tab (or spaces) in front of the node "formattedNode" within the CDATA gets removed.
Content within CDATA shouldn't get touched in anyway.

Formatter Implementation

default / not changed

XML Tools Version

XML Tools Version 2.5.0

VS Code Version

Visual Studio Code 1.40.2

Operating System

Windows 10

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions