feat: add suggestions to no-empty-blocks - #479
Conversation
|
Thank you for the PR. Just found two small refactorings using more appropriate methods. |
7790a62 to
a91126c
Compare
a91126c to
9c140f5
Compare
| { | ||
| messageId: "convertToStatement", | ||
| fix: fixer => | ||
| fixer.replaceText(node, ";"), |
There was a problem hiding this comment.
The fixer currently only replaces the block node, which preserves any whitespace before {} and can produce output like @layer foo ;. Could we include the preceding whitespace in the replacement range so the fix produces @layer foo;?
There was a problem hiding this comment.
sorry, i did indeed lose track of this PR.
I did this using node.prelude.loc.end...node.loc.end, not sure if there's a more idiomatic solution
|
Hi everyone, it looks like we lost track of this pull request. Please review and see what the next steps are. This pull request will auto-close in 7 days without an update. |
9c140f5 to
d70549d
Compare
Prerequisites checklist
AI acknowledgment
(If the above is not checked) I have reviewed the AI-generated content before submitting.What is the purpose of this pull request?
Add sugggestions to
no-empty-blocks. There are two different cases:@layer name {}becomes@layer namea {}become. This included unnamed layers such as@layer {}.What changes did you make? (Give an overview)
Related Issues
Closes #476
Is there anything you'd like reviewers to focus on?
@layeras mentioned above). I have asked a senior colleague and Claude Opus 4.8, both of whom agreed.