ESLint
87 rules eslint@10.12.0
Complete effective rule inventory.
Rules
No enabled ESLint rules match this search.
-
no-unsafe-optional-chainingDisallow use of optional chaining in contexts where the
undefinedvalue is not allowed: error in All ESLint contexts -
no-unused-labelsDisallow unused labels
: warning in All ESLint contexts -
no-unused-private-class-membersDisallow unused private class members
: warning in All ESLint contexts -
no-useless-assignmentDisallow variable assignments when the value is not used
: warning in All ESLint contexts -
no-useless-backreferenceDisallow useless backreferences in regular expressions
: warning in All ESLint contexts -
no-useless-catchDisallow unnecessary
catchclauses: warning in All ESLint contexts -
no-useless-computed-keyDisallow unnecessary computed property keys in objects and classes
: error in All ESLint contexts -
no-useless-escapeDisallow unnecessary escape characters
: warning in All ESLint contexts -
no-useless-renameDisallow renaming import, export, and destructured assignments to the same name
: error in All ESLint contexts -
no-useless-returnDisallow redundant return statements
: error in All ESLint contexts -
no-varRequire
letorconstinstead ofvar: error in All ESLint contexts -
no-withDisallow
withstatements: warning in JavaScript source, React JavaScript source -
object-shorthandRequire or disallow method and property shorthand syntax for object literals
: error in All ESLint contexts -
prefer-arrow-callbackRequire using arrow functions for callbacks
: error in All ESLint contexts -
prefer-constRequire
constdeclarations for variables that are never reassigned after declared: error in All ESLint contexts -
prefer-object-has-ownDisallow use of
Object.prototype.hasOwnProperty.call()and prefer use ofObject.hasOwn(): error in All ESLint contexts -
prefer-rest-paramsRequire rest parameters instead of
arguments: error in TypeScript source, React source, TypeScript tests, Bun tests, Playwright end-to-end tests, Syntax-only tool configuration, Design-system React source -
prefer-spreadRequire spread operators instead of
.apply(): error in TypeScript source, React source, TypeScript tests, Bun tests, Playwright end-to-end tests, Syntax-only tool configuration, Design-system React source -
prefer-templateRequire template literals instead of string concatenation
: error in All ESLint contexts -
preserve-caught-errorDisallow losing originally caught error when re-throwing custom errors
: warning in All ESLint contexts -
require-yieldRequire generator functions to contain
yield: warning in All ESLint contexts -
use-isnanRequire calls to
isNaN()when checking forNaN: warning in All ESLint contexts -
valid-typeofEnforce comparing
typeofexpressions against valid strings: warning in All ESLint contexts