Skip to content

vue/html-self-closing-bracket-newline #1794

Closed
@olemarius

Description

@olemarius

Please describe what the rule should do:

I'd like to set multiline: 'always' for self-closing tags

<MyComp
    :foo="bar"
/>

And singleline: 'never'

<MyComp :foo="bar" />

And multiline: 'never' for tags with content.

<MyComp
    :foo="bar">
    Hello World
</MyComp>

What category should the rule belong to?

[x] Enforces code style (layout)
[ ] Warns about a potential error (problem)
[ ] Suggests an alternate way of doing something (suggestion)
[ ] Other (please specify:)

Provide 2-3 code examples that this rule should warn about:

// singleline: 'never'
<MyComp :foo="bar"
/>
// multiline: 'always'    
<MyComp 
  :foo="bar" />

Additional context

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions