vscode-xml icon indicating copy to clipboard operation
vscode-xml copied to clipboard

Support equivalent of html.format.wrapAttributes: force-aligned

Open kibiz0r opened this issue 6 years ago • 2 comments

Description What would you like to see added to XML Tools?

I would like XML Tools to support the same "wrap attributes" modes as the built-in HTML modes, but especially "force-aligned".

My team formats their XML like this:

<myThingy attr1="val1"
          attr2="val2"
          ...>

While "xmlTools.splitAttributesOnFormat" only supports indenting by your standard "indent" amount, rather than keeping the attributes aligned.

e.g.

<myThingy attr1="val1"
    attr2="val2"
    ...>

Current Workarounds Are you using a workaround in the meantime?

Right now, I'm just associating my XML files with the HTML filetype so that I can use the "force-aligned" mode. This is really awkward, because it means turning off all HTML suggestions/validations, and prohibits me from using other XML-associated tools.

kibiz0r avatar Jul 23 '18 12:07 kibiz0r

Big thumbs up for this idea, particularly in combination with #245 .

johncrim avatar Jul 27 '19 18:07 johncrim

+1

bobslee avatar May 26 '24 17:05 bobslee