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): [explicit-member-accessibility] report TSAbstractPropertyDefinition
and TSAbstractMethodDefinition
properly
#3901
Conversation
Thanks for the PR, @rafaelss95! 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. |
TSAbstractClassProperty
not being reportedTSAbstractClassProperty
properly
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 fixing this so fast!
Your change here LGTM.
But there's one thing that's worth mentioning.
Previously the rule completely ignored abstract members. However now it will check them. This will likely cause a lot of new reports on existing codebase.
So I'm going to mark this as a breaking change.
This is perfectly fine as we're already working on the next major - i've update the target branch of your change.
Could you please rebase on the v5
branch?
@@ -274,7 +275,8 @@ export default util.createRule<Options, MessageIds>({ | |||
|
|||
return { | |||
TSParameterProperty: checkParameterPropertyAccessibilityModifier, | |||
ClassProperty: checkPropertyAccessibilityModifier, | |||
'ClassProperty, TSAbstractClassProperty': | |||
checkPropertyAccessibilityModifier, | |||
MethodDefinition: checkMethodAccessibilityModifier, |
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.
while we're here we should also handle abstract methods
MethodDefinition: checkMethodAccessibilityModifier, | |
'MethodDefinition, TSAbstractMethodDefinition': checkMethodAccessibilityModifier, |
…tPropertyDefinition` and `TSAbstractMethodDefinition` properly
07ea7bc
to
7a5f897
Compare
TSAbstractClassProperty
properlyTSAbstractPropertyDefinition
and TSAbstractMethodDefinition
properly
I just did the updates. Let me know if I miss something. |
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 - thanks for this!
…tPropertyDefinition` and `TSAbstractMethodDefinition` properly (#3901)
…tPropertyDefinition` and `TSAbstractMethodDefinition` properly (#3901)
…tPropertyDefinition` and `TSAbstractMethodDefinition` properly (#3901)
Fixes #3835.