Skip to content

Conversation

@ota-meshi
Copy link
Member

This PR adds vue/multiline-html-element-content-newline rule.
This implements rule proposed in #547 (comment)

It is related to #415.

schema: [{
type: 'object',
properties: {
'ignoreNames': {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps we should stick to the convention and use simple ignore property? I don't have strong preference though

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for review!
Name was unnecessary.
Since the indent rule is named ignores, we also name it ignores.

</div>
</template>`,
errors: [
'Expected 1 line break after closing bracket of the "div" element, but no line breaks found.',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I find closing bracket and opening bracket a little confusing. What do you think about instead using opening tag and closing tag?
So for example:

Expected 1 line break after opening tag (`<div>`), but no line breaks found.

and

Expected 1 line break before closing tag (`</div>`), but no line breaks found.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for review!
The message you suggested is very easy to understand.

@ota-meshi
Copy link
Member Author

@michalsnik I changed it! so please check again.

Copy link
Member

@michalsnik michalsnik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! ⭐️

@michalsnik michalsnik merged commit e53bfd3 into master Aug 13, 2018
@michalsnik michalsnik deleted the add-rule/multiline-html-element-content-newline branch August 13, 2018 23:22
@armano2
Copy link
Contributor

armano2 commented Nov 13, 2018

sadly i found issue in this rule: #662

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants