Like with sonar-java and the annotation @SuppressWarnings("squid:S2078"),
is there any way with sonar-js to ignore one rule on a block of code ??
The git repo doesn't have any exemple of that.
I develop a react-redux ES6 app and i have reducer with default value :
export default function myReducer(prev = initialState, action)
and Sonar complain with "Function parameters with default values should be last".
But i can't change the order of the parameters of a reducer and i need a default value.
The options you have:
in your project administration in SQ you can set up ignoring some files for some rule (see docs)
you mark issues in SQ as "won't fix"
you put "// NOSONAR" comment in the line with issue
You can also report false-positive issue in SonarJS github issues.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With