sonarjs/prefer-specific-assertions
eslint-plugin-sonarjs
SuggestionRecommended
eslint.config.js
export default [
{
rules: {
"sonarjs/prefer-specific-assertions": "error",
},
},
];No code example for this rule
The linters' documentation does not include one we could extract.
sonarjs/prefer-specific-assertions
eslint-plugin-sonarjs
export default [
{
rules: {
"sonarjs/prefer-specific-assertions": "error",
},
},
];Oxlint does not have this rule.
Biome does not have this rule.
Return of boolean expressions should not be wrapped into an "if-then-else" statement
"RegExp.exec()" should be preferred over "String.match()"
Debugging features should not be enabled in production
Pseudorandom number generators (PRNGs) should not be used in security contexts