-
-
Notifications
You must be signed in to change notification settings - Fork 48
feat: add svelte/html-closing-bracket-spacing
#186
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
Conversation
…, fixer remove child whitespace
…here is no value (key="")
Thank you for this PR! |
@ota-meshi I've added the docs, fixed the merge conflicts and both the docs build and lint should be passing now! |
Thank you for adding the documentation! I'm busy this week so I'll probably check it next week. |
I had extra time today, so I have added <div/>
# gets fixed to
<div /> It's similar to to The test also has 100% coverage I've also fixed some minor problems in my docs (such as since version being 0.2.2, which is already released, or mistyped |
svelte/html-self-closing
and svelte/no-spaces-around-equal-signs-in-attribute
rulessvelte/html-closing-bracket-spacing
, svelte/html-self-closing
and svelte/no-spaces-around-equal-signs-in-attribute
rules
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.
Thank you for this PR!
I have change requests.
I've looked at the source code for one rule, but I'll check the rest after tomorrow.
If possible, can you separate the PR for each rule? |
If you want to create new rules besides these, you may find it useful to use |
… rename any to ignore in html-closing-bracket-spacing
svelte/html-closing-bracket-spacing
, svelte/html-self-closing
and svelte/no-spaces-around-equal-signs-in-attribute
rulessvelte/html-closing-bracket-spacing
Hi @marekvospel Can you update this PR’s description align to its actual content? |
sure |
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.
Thank you for changing this PR. Also, thank you for splitting the PR.
I commented only one. Other than that, it looks good to me.
Personally thinking, |
Hmm. I'm not sure if the stylistic rules should be an another plugin. |
ESLint core has frozen their stylistic rules, no new related rule will be added, and no new feature for these rules will be added neither. |
I know that, but plugin for Svelte doesn't freeze the stylistic rules. If we continue to discuss what to do with stylistic rules, it may be better to open a new issue and discuss it there. |
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!
@marekvospel Thank you for your great contribution! I will release the next version when the rest of the rules are complete. |
Added
html-closing-bracket-spacing
rule, which can be seen ineslint-plugin-vue
Related PRs
feat: add
svelte/html-self-closing
#190feat: add
svelte/no-spaces-around-equal-signs-in-attribute
#191svelte/html-closing-bracket-spacing
A simple rule for enforcing a space before closing a tag
Coverage
100% test coverage.
Notes & questionsThis is my first time contributing to this project and creating eslint plugins in general, so I'm sorry if some parts of my code aren't as good.How should I document the rules? Is there a script to automatically generate the documentation, or should I create a new markdown file insidedocs/rules
? (This information should probably be added to contributing section in README)