Enforce `return` statements in callbacks of array methods
Require braces around arrow function bodies
Enforce camelcase naming convention
Require `super()` calls in constructors
Enforce consistent brace style for all control statements
Require the use of `===` and `!==`
Enforce `for` loop update clause moving the counter in the right direction
Enforce `return` statements in getters
Enforce minimum and maximum identifier lengths
Require or disallow logical assignment operator shorthand
Enforce a maximum number of classes per file
Enforce a maximum depth that blocks can be nested
Enforce a maximum number of lines per file
Enforce a maximum number of lines of code in a function
Disallow the use of `alert`, `confirm`, and `prompt`
Disallow `Array` constructors
Disallow using an async function as a Promise executor
Disallow reassigning class members
Disallow assignment operators in conditional expressions
Disallow the use of `console`
Disallow reassigning `const` variables
Disallow constant expressions in conditions
Disallow control characters in regular expressions
Disallow duplicate arguments in `function` definitions
Disallow duplicate class members
Disallow duplicate keys in object literals
Disallow `else` blocks after `return` statements in `if` statements
Disallow empty block statements
Disallow empty character classes in regular expressions
Disallow empty destructuring patterns
Disallow empty static blocks
Disallow reassigning exceptions in `catch` clauses
Disallow unnecessary boolean casts
Disallow reassigning `function` declarations
Disallow assigning to imported bindings
Disallow inline comments after code
Disallow irregular whitespace
Disallow labeled statements
Disallow unnecessary nested blocks
Disallow `if` statements as the only statement in `else` blocks
Disallow literal numbers that lose precision
Disallow multiline strings
Disallow `new` operators with global non-constructor functions
Disallow calling global object properties as functions
Disallow variable redeclaration
Disallow multiple spaces in regular expressions
Disallow specified syntax
Disallow assignment operators in `return` statements
Disallow assignments where both sides are exactly the same
Disallow comparisons where both sides are exactly the same
Disallow returning values from setters
Disallow variable declarations from shadowing variables declared in the outer scope
Disallow template literal placeholder syntax in regular strings
Disallow `this`/`super` before calling `super()` in constructors
Disallow the use of undeclared variables unless mentioned in `/*global */` comments
Disallow initializing variables to `undefined`
Disallow confusing multiline expressions
Disallow unmodified loop conditions
Disallow ternary operators when simpler alternatives exist
Disallow unreachable code after `return`, `throw`, `continue`, and `break` statements
Disallow control flow statements in `finally` blocks
Disallow negating the left operand of relational operators
Disallow unused expressions
Disallow unused private class members
Disallow unused variables
Disallow the use of variables before they are defined
Disallow useless backreferences in regular expressions
Disallow unnecessary computed property keys in objects and classes
Disallow unnecessary constructors
Disallow renaming import, export, and destructured assignments to the same name
Disallow redundant return statements
Require `let` or `const` instead of `var`
Require or disallow method and property shorthand syntax for object literals
Enforce variables to be declared either together or separately in functions
Require using arrow functions for callbacks
Require `const` declarations for variables that are never reassigned after declared
Require destructuring from arrays and/or objects
Require rest parameters instead of `arguments`
Require spread operators instead of `.apply()`
Require or disallow Unicode byte order mark (BOM)
Require or disallow "Yoda" conditions
Reflows single-line comments to ensure that blocks never exceed the configured length
Reflows multi-line comments to ensure that blocks never exceed the configured length
Require a `eslint-enable` comment for every `eslint-disable` comment
Disallow a `eslint-enable` comment for multiple `eslint-disable` comments
Disallow duplicate `eslint-disable` comments
Disallow `eslint-disable` comments without rule names
Disallow unused `eslint-enable` comments
Require include descriptions in ESLint directive-comments
Checks that `@access` tags have a valid value.
Reports invalid alignment of JSDoc block asterisks.
Ensures that parameter names in JSDoc match those in the function declaration.
Ensures that property names in JSDoc are not duplicated on the same block and that nested properties have defined roots.
Converts non-JSDoc comments preceding or following nodes into JSDoc ones
Expects specific tags to be empty of any content.
Reports an issue with any non-constructor function using `@implements`.
This rule reports doc comments that only restate their attached name.
Controls how and whether jsdoc blocks can be expressed as single or multiple line blocks.
Detects and removes extra lines of a blank block description
Removes empty blocks with nothing but possibly line breaks
This rule reports defaults being used on the relevant portion of `@param` or `@default`.
Prevents use of multiple asterisks at the beginning of lines.
This rule reports types being used on `@param` or `@returns`.
Requires that each JSDoc line starts with an `*`.
Requires that all functions have a description.
Requires that block description, explicit `@description`, and `@param`/`@returns` tag descriptions are written in complete sentences.
Requires a hyphen before the `@param` description.
Requires that all function parameters are documented.
Requires that each `@param` tag has a `description` value.
Requires that all function parameters have names.
Requires that all `@typedef` and `@namespace` tags have `@property` when their type is a plain `object`, `Object`, or `PlainObject`.
Requires that each `@property` tag has a `description` value.
Requires that all function `@property` tags have names.
Requires that returns are documented.
Requires a return statement in function body if a `@returns` tag is specified in jsdoc comment.
Requires that the `@returns` tag has a `description` value.
Requires template tags for each generic type parameter
Requires a yield statement in function body if a `@yields` tag is specified in jsdoc comment.
Sorts tags by a specified sequence according to tag name.
Having line breaks styles to object, array and named imports
Fix duplication in imports
Prevent importing modules in `dist` folder
Prevent importing modules in `node_modules` folder by relative or absolute path
Prevent using top-level await
Enforce top-level functions to be declared with function keyword
Forbid namespace (a.k.a. "wildcard" `*`) imports.
Forbid the use of mutable exports with `var` or `let`.
Forbid a module from importing itself.
Forbid named default exports.
Forbid repeated import of the same module in multiple places.
Ensure all imports appear before other statements.
Forbid webpack loader syntax in imports.
Enforce a convention in module import order.
Enforce a newline after import statements.
Automatically sort imports.
Automatically sort exports.
Enforce consistent param names and ordering when creating new promises.
Disallow wrapping values in `Promise.resolve` or `Promise.reject` when not needed.
Require returning inside each `then()` to create readable and reusable Promise chains.
Enforce the use of `catch()` on un-returned promises.
Prefer `async`/`await` to the callback pattern.
Prefer `await` to `then()`/`catch()`/`finally()` for reading Promise values.
Require creating a `Promise` constructor before using it in an ES5 environment.
Disallow calling `cb()` inside of a `then()` (use [util.callbackify][] instead).
Disallow using promises inside of callbacks.
Disallow nested `then()` or `catch()` statements.
Disallow creating `new` promises outside of utility libs (use [util.promisify][] instead).
Disallow calling `new` on a Promise static method.
Disallow return statements in `finally()`.
Disallow creating new promises with paths that resolve multiple times.
Prefer class properties to assignment of literals in constructors.
Prefer early returns over full-body conditional wrapping in function declarations.
Prefer that screaming snake case variables always be defined using `const`, and always appear at module scope.
Restrict the number of returned items from React hooks.
Prevent module imports between components.
Enforce Pascal case when naming enums.
Prefer singular TypeScript enums.
"if ... else if" constructs should end with "else" clauses
Mergeable "if" statements should be combined
Boolean literals should not be used in comparisons
Return of boolean expressions should not be wrapped into an "if-then-else" statement
String literals should not be duplicated
A "while" loop should be used instead of a "for" loop
"switch" statements should not have too many "case" clauses
Local variables should not be declared and then immediately returned or thrown
Loops with at most one iteration should be refactored
Identical expressions should not be used on both sides of a binary operator
"switch" statements should not be nested
"if/else if" chains and "switch" cases should not have the same condition
Two branches in a conditional structure should not have exactly the same implementation
Boolean checks should not be inverted
Return values from functions without side effects should not be ignored
Object literal syntax should be used
Boolean expressions should not be gratuitous
"catch" clauses should do more than rethrow
Non-existent operators '=+', '=-' and '=!' should not be used
Jump statements should not be redundant
The return value of void functions should not be used
Cognitive Complexity of functions should not be too high
All branches in a conditional structure should not have exactly the same implementation
Collection contents should be used
Collection elements should not be replaced unconditionally
Functions should not have identical implementations
Empty collections should not be accessed or iterated
Template literals should not be nested
Enforce a specific parameter name in catch clauses.
Use destructured variables over properties.
Move function definitions to the highest possible scope.
Enforce no spaces between braces.
Enforce a case style for filenames.
Prefer `for…of` over the `forEach` method.
Enforce combining multiple `Array#push()` into one call.
Disallow member access from await expression.
Do not use a `for` loop that can be replaced with a `for-of` loop.
Disallow identifiers starting with `new` or `class`.
Disallow `if` statements as the only statement in `if` blocks without `else`.
Disallow negated conditions.
Disallow negated expression in equality check.
Disallow nested ternary expressions.
Disallow the use of objects as default parameters.
Disallow classes that only have static members.
Disallow unreadable array destructuring.
Disallow unused object properties.
Disallow returning/yielding `Promise.resolve/reject()` in async functions or promise callbacks
Disallow unnecessary spread.
Disallow useless `undefined`.
Enforce proper case for numeric literals.
Prefer default parameters over reassignment.
Prefer `export…from` when re-exporting.
Prefer `.includes()` over `.indexOf()`, `.lastIndexOf()`, and `Array#some()` when checking for existence or non-existence.
Prefer using a logical operator over a ternary.
Prefer `Math.min()` and `Math.max()` over ternaries for simple comparisons.
Prefer omitting the `catch` binding parameter.
Prefer `Set#has()` over `Array#includes()` when checking for existence or non-existence.
Prefer `switch` over multiple `else-if`.
Prefer ternary expressions over simple `if-else` statements.
Enforce consistent brace style for `case` clauses.
Fix whitespace-insensitive template indentation.
Set a max param number for your constructors, functions, methods etc.
Transforms the negation of a conjunction !(A && B) into the equivalent !A || !B according to De Morgan’s law
Transforms the negation of a disjunction !(A || B) into the equivalent !A && !B according to De Morgan’s law
Require that function overload signatures be consecutive
Require consistently using either `T[]` or `Array<T>` for arrays
Disallow `@ts-<directive>` comments or require descriptions after directives
Enforce specifying generic type arguments on type annotation or constructor name of a constructor call
Require or disallow the `Record` type
Enforce type definitions to consistently use either `interface` or `type`
Enforce consistent usage of type imports
Enforce default parameters to be last
Require explicit return types on functions and class methods
Require explicit accessibility modifiers on class properties and methods
Enforce using a particular method signature syntax
Disallow generic `Array` constructors
Disallow non-null assertion in locations that may be confusing
Disallow duplicate class members
Disallow duplicate enum member values
Disallow using the `delete` operator on computed key expressions
Disallow accidentally using the "empty object" type
Disallow extra non-null assertions
Disallow classes used as namespaces
Disallow iterating over an array with a for-in loop
Enforce the use of top-level import type qualifier when an import only has specifiers with inline type qualifiers
Disallow explicit type declarations for variables or parameters initialized to a number, string, or boolean
Disallow `void` type outside of generic or return types
Enforce valid definition of `new` and `constructor`
Disallow TypeScript namespaces
Disallow non-null assertions in the left operand of a nullish coalescing operator
Disallow non-null assertions after an optional chain expression
Disallow non-null assertions using the `!` postfix operator
Disallow variable redeclaration
Disallow invocation of `require()`
Disallow variable declarations from shadowing variables declared in the outer scope
Disallow unnecessary constraints on generic types
Disallow unsafe declaration merging
Disallow using the unsafe built-in Function type
Disallow unused expressions
Disallow unused variables
Disallow the use of variables before they are defined
Disallow unnecessary constructors
Disallow using confusing built-in primitive class wrappers
Enforce the use of `as const` over literal type
Enforce the use of `for-of` loop over the standard `for` loop where possible
Enforce using function types instead of interfaces with call signatures
Require all enum members to be literal values
Require using `namespace` keyword over `module` keyword to declare custom TypeScript modules
Disallow certain triple slash directives in favor of ES6-style import declarations
Disallow two overloads that could be unified into one with a union or an optional/rest parameter
Enforce sorted variable declarations.
Enforce sorted intersection types.
Enforce sorted heritage clauses.
Enforce sorted arrays before include method.
Enforce sorted object types.
Enforce sorted union types.
Enforce sorted switch cases.
Enforce sorted interface properties.
Enforce sorted JSX props.
Enforce sorted TypeScript enums.
Enforce sorted Map elements.
Enforce arrow function return style
Disallow export default anonymous arrow function<br/>_**Automatically fix using the current file name.**_
Enforce linebreaks after opening and before closing array brackets
Enforce consistent spacing inside array brackets
Enforce line breaks after each array element
Require parentheses around arrow function arguments
Enforce consistent spacing before and after the arrow in arrow functions
Disallow or enforce spaces inside of blocks after opening block and before closing block
Enforce consistent brace style for blocks
Require or disallow trailing commas
Enforce consistent spacing before and after commas
Enforce consistent comma style
Enforce consistent spacing inside computed property brackets
Enforce consistent newlines before and after dots
Require or disallow newline at the end of files
Require or disallow spacing between function identifiers and their invocations
Enforce line breaks between arguments of a function call
Require or disallow spacing between function identifiers and their invocations
Enforce consistent line breaks inside function parentheses
Enforce consistent spacing around `*` operators in generator functions
Enforce the location of arrow function bodies
Enforce consistent indentation
Indentation for binary operators
Enforce or disallow spaces inside of curly braces in JSX attributes and expressions
Enforce closing bracket location in JSX
Enforce closing tag location for multiline JSX
Disallow unnecessary JSX expressions when literals alone are sufficient or enforce JSX expressions on literals in JSX children or attributes
Enforce consistent linebreaks in curly braces in JSX attributes and expressions
Enforce or disallow spaces inside of curly braces in JSX attributes and expressions
Enforce or disallow spaces around equal signs in JSX attributes
Enforce proper position of the first property in JSX
Enforce line breaks before and after JSX elements when they are used as arguments to a function.
Enforce props indentation in JSX
Enforce maximum of props on a single line in JSX
Require or prevent a new line after jsx elements and expressions.
Require one JSX element per line
Disallow multiple spaces between inline JSX props
Enforce the consistent use of either double or single quotes in JSX attributes
Enforce whitespace in and around the JSX opening and closing brackets
Disallow missing parentheses around multiline JSX
Enforce consistent spacing between property names and type annotations in types and interfaces
Enforce consistent spacing before and after keywords
Enforce consistent linebreak style
Require empty lines around comments
Require or disallow an empty line between class members
Enforce a maximum line length
Enforce a maximum number of statements allowed per line
Require a specific member delimiter style for interfaces and type literals
Enforce a particular style for multiline comments
Enforce newlines between operands of ternary expressions
Enforce or disallow parentheses when invoking a constructor with no arguments
Require a newline after each call in a method chain
Disallow arrow functions where they could be confused with comparisons
Disallow unnecessary parentheses
Disallow unnecessary semicolons
Disallow leading or trailing decimal points in numeric literals
Disallow mixed binary operators
Disallow mixed spaces and tabs for indentation
Disallow multiple empty lines
Disallow trailing whitespace at the end of lines
Disallow whitespace before properties
Enforce the location of single-line statements
Enforce consistent line breaks after opening and before closing braces
Enforce consistent spacing inside braces
Enforce placing object properties on separate lines
Require or disallow newlines around variable declarations
Enforce consistent linebreak style for operators
Require or disallow padding within blocks
Require or disallow padding lines between statements
Require quotes around object literal, type literal, interfaces and enums property names
Enforce the consistent use of either backticks, double, or single quotes
Enforce spacing between rest and spread operators and their expressions
Require or disallow semicolons instead of ASI
Enforce consistent spacing before and after semicolons
Enforce location of semicolons
Enforce consistent spacing before blocks
Enforce consistent spacing before function parenthesis
Enforce consistent spacing inside parentheses
Require spacing around infix operators
Enforce consistent spacing before or after unary operators
Enforce consistent spacing after the `//` or `/*` in a comment
Enforce spacing around colons of switch statements
Require or disallow spacing around embedded expressions of template strings
Require or disallow spacing between template tags and their literals
Require consistent spacing around type annotations
Enforces consistent spacing inside TypeScript type generics
Expect space before the type declaration in the named tuple
Require parentheses around immediate `function` invocations
Require parenthesis around regex literals
Require or disallow spacing around the `*` in `yield*` expressions
Enforce `test` and `it` usage conventions
Enforce assertion to be made in a test body
Enforces a maximum number assertion calls in a test body
Enforces a maximum depth to nested describe calls
Disallow commented out tests
Disallow calling `expect` conditionally
Disallow conditional logic in tests
Disallow using a callback in asynchronous tests and hooks
Disallow duplicate setup and teardown hooks
Disallow using `exports` in files containing tests
Disallow identical titles
Disallow using `expect` outside of `it` or `test` blocks
Require using `.only` and `.skip` over `f` and `x`
Disallow using `jest.mock()` factories without an explicit type parameter
Enforce padding around Jest functions
Suggest using `toBeCalledWith()` or `toHaveBeenCalledWith()`
Suggest using the built-in comparison matchers
Prefer using `.each` rather than manual loops
Suggest using the built-in equality matchers
Prefer having hooks in a consistent order
Enforce lowercase test names
Suggest using `toStrictEqual()`
Suggest using `toBe()` for primitive literals
Suggest using `toContain()`
Suggest using `toHaveLength()`
Suggest using `test.todo`
Require setup and teardown code to be within a hook
Require a message for `toThrow()`
Require test cases and hooks to be inside a `describe` block
Enforce unbound methods are called with their expected scope
Enforce valid `describe()` callback
Require promises that have expectations in their chain to be valid
Enforce valid `expect()` usage
Disallow or enforce spaces inside of brackets
Require or disallow trailing commas
Enforce consistent comma style
Enforce consistent indentation
Enforce consistent spacing between keys and values in object literal properties
Disallow binary expression
Disallow binary numeric literals
Disallow duplicate keys in object literals
Disallow escape sequences in identifiers.
Disallow leading or trailing decimal points in numeric literals
Disallow hexadecimal numeric literals
Disallow multiline strings
Disallow number property keys
Disallow numeric separators
Disallow octal escape sequences in string literals
Disallow octal numeric literals
Disallow legacy octal literals
Disallow parentheses around the expression
Disallow template literals
Disallow Unicode code point escape sequences.
Disallow unnecessary escape usage
Enforce consistent line breaks inside braces
Enforce consistent spacing inside braces
Enforce placing object properties on separate lines
Require quotes around object literal property names
Enforce use of double or single quotes
Require object keys to be sorted
Disallow spaces after unary operators
Disallow invalid number for JSON
Reports on unnecessary empty arrays and objects.
Prevents adding unnecessary / redundant files.
Package properties must be declared in standard order
Enforce either object or shorthand declaration for repository.
Dependencies, scripts, and configuration values must be declared in alphabetical order.
Checks a dependency isn't specified more than once (i.e. in `dependencies` and `devDependencies`)
Checks existence of local dependencies in the package.json
Enforce that package names are valid npm package names
Enforce that package.json has all properties required by the npm spec
Enforce that if repository directory is specified, it matches the path to the package.json file
Enforce that package versions are valid semver specifiers
Enforce consistent line breaks after `:` indicator
Enforce consistent line breaks after `?` indicator
Require or disallow block style mappings.
Enforce consistent line breaks after `-` indicator
Require or disallow block style sequences.
Enforce YAML file extension
Enforce consistent line breaks inside braces
Enforce consistent spacing inside braces
Enforce linebreaks after opening and before closing flow sequence brackets
Enforce consistent spacing inside flow sequence brackets
Enforce consistent indentation
Enforce consistent spacing between keys and values in mapping pairs
Disallow empty mapping keys
Disallow empty sequence entries
Disallow irregular whitespace
Disallow tabs for indentation.
Require or disallow plain style scalar.
Enforce the consistent use of either double, or single quotes
Enforce consistent spacing after the `#` in a comment
Enforce linebreaks after opening and before closing array brackets
Enforce consistent spacing inside array brackets
Enforce line breaks between array elements
Enforce consistent comma style in array
Enforce consistent indentation
Enforce consistent spacing inside braces
Enforce consistent spacing between keys and values in key/value pairs
Disallow defining pair keys out-of-order
Disallow spacing around infix operators
Disallow number separators that to not enhance readability.
Require or disallow padding lines between pairs
Require or disallow padding lines between tables
Disallow precision of fractional seconds greater than the specified value.
Disallow precision of integer greater than the specified value.
Require or disallow quotes around keys
Enforce consistent spacing after the `#` in a comment
Enforce consistent spacing inside table brackets
Disallow defining tables out-of-order
Use Prettier to format code
Migrate builtin and `@typescript-eslint` stylistic rules to `@stylistic` rules