Skip to content

ESLint

88 rules eslint@10.11.0

Complete effective rule inventory.

Docs

Rules

8 rules on this page · 88 total

  • prefer-object-has-own

    Disallow use of Object.prototype.hasOwnProperty.call() and prefer use of Object.hasOwn()

    : error in All ESLint contexts
    Autofix available
  • prefer-rest-params

    Require 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
    No autofix
  • prefer-spread

    Require 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
    Autofix available
  • prefer-template

    Require template literals instead of string concatenation

    : error in All ESLint contexts
    Autofix available
  • preserve-caught-error

    Disallow losing originally caught error when re-throwing custom errors

    : warning in All ESLint contexts
    No autofix; suggestions available
  • require-yield

    Require generator functions to contain yield

    : warning in All ESLint contexts
    No autofix
  • use-isnan

    Require calls to isNaN() when checking for NaN

    : warning in All ESLint contexts
    No autofix; suggestions available
  • valid-typeof

    Enforce comparing typeof expressions against valid strings

    : warning in All ESLint contexts
    No autofix; suggestions available