-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
fix(eslint-plugin): [padding-line-between-statements] make function overloading is also processed #4345
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
fix(eslint-plugin): [padding-line-between-statements] make function overloading is also processed #4345
Conversation
Thanks for the PR, @lonyele! typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community. The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately. Thanks again! 🙏 Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently on https://opencollective.com/typescript-eslint. As a thank you, your profile/company logo will be added to our main README which receives thousands of unique visitors per day. |
❌ Deploy Preview for typescript-eslint failed. 🔨 Explore the source changes: d6f38f1 🔍 Inspect the deploy log: https://app.netlify.com/sites/typescript-eslint/deploys/61c6f4ef126b8a0007a6b806 |
Codecov Report
@@ Coverage Diff @@
## main #4345 +/- ##
==========================================
+ Coverage 93.88% 94.20% +0.31%
==========================================
Files 297 152 -145
Lines 11179 8104 -3075
Branches 3246 2592 -654
==========================================
- Hits 10495 7634 -2861
+ Misses 416 266 -150
+ Partials 268 204 -64
Flags with carried forward coverage won't be shown. Click here to find out more. |
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.
thanks for this!
PR Checklist
Overview
Problem
normal function overloading was not processed at all because
TSDeclareFunction
was not called at all. Cases such as below should have made error that there is a blank space expectedWhat I did
TSDeclareFunction
is also processed.Context
I may be wrong because as I think more about it new approaches showing up but let's give it a shot
Issue provided 3 cases
because
block-like
(curly brace at last token) and*
are matched thus rule applies. To make this work like issue is saying, I think this option can override the option withblock-like
But It wasn't because
TSDeclareFunction
was ignored for this rule. This PR fixes it. This option can be used to work as issuer intendedI found this
lines-between-class-members
rule and it is the one that is taking care of the lines inside of class