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
Add rule S6747 (no-unknown-property
): JSX elements should not use unknown properties and attributes
#4146
Conversation
no-unknown-property
): Disallow usage of unknown DOM propertyno-unknown-property
): JSX elements should not use unknown properties and attributes
2387086
to
bf1dcdb
Compare
@@ -17,11 +17,11 @@ | |||
* along with this program; if not, write to the Free Software Foundation, |
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.
The changes on this file were required to also consider .jsx
files triggering quick fixes.
@Rule(key = "S6747") | ||
public class NoUnknownPropertyCheck implements EslintBasedCheck { | ||
|
||
@RuleProperty( |
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.
In general, I would avoid as much as possible to include properties to a rule. However, if we don't provide this feature, I am afraid too many users will complain about false positives.
Please let me know if that makes sense to you, or if we should drop that property :)
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.
Yes, I agree that it is necessary - that was my first thought when I was reading the rule source.
…nknown properties and attributes
bf1dcdb
to
cd2181b
Compare
SonarQube Quality Gate |
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
Fixes #4144