Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent splitAttributes from splitting elements with one attribute #59

Closed
alesso-x opened this issue Oct 11, 2018 · 1 comment
Closed
Assignees
Labels
enhancement New feature or request formatting
Milestone

Comments

@alesso-x
Copy link

When splitAttributes is enabled, elements with one attribute get split onto multiple line. For example:

<myelement key="some_key">hellow</myelement>

becomes

<myelement
          key="some_key">hellow</myelement>

The splitAttributes comment says it will split multiple attributes onto a new line. I'm not sure if this is the expected behavior but it would nice to have elements with one attribute stay on the same line.

// Split multiple attributes each onto a new line
"xml.format.splitAttributes": true,
@NikolasKomonen
Copy link
Contributor

@alessandrodimarco Thanks for pointing this out, you're right. It'll be fixed in the next release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request formatting
Projects
None yet
Development

No branches or pull requests

3 participants