-
-
Notifications
You must be signed in to change notification settings - Fork 677
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
[New] Add vue/singleline-html-element-content-newline
rule
#552
[New] Add vue/singleline-html-element-content-newline
rule
#552
Conversation
} | ||
``` | ||
|
||
- `strict` ... if false, if there are no attributes on the element, this rule allows having contents in one line. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What do you think about renaming strict
option that I proposed earlier to something a bit more descriptive, like ignoreWhenNoAttribures
?
- `ignoreWhenNoAttributes` ... allows having contents in one line, when given element has no attributes. default `true`
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that the name ignoreWhenNoAttribures
is easy to understand and very good!
</template> | ||
`, | ||
errors: [ | ||
'Expected 1 line break after closing bracket of the "div" element, but no line breaks found.', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same question as in the other rule, what do you think about using opening tag
and closing tag
phrases?
…s` and report messages
@michalsnik Thank you for the review! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
This PR adds
vue/singleline-html-element-content-newline
rule.This implements rule proposed in #547 (comment)
It is related to #415.