talira

eslint-plugin-react

React-specific linting rules for ESLint

open sourceMITfree

eslint-plugin-react adds React-specific rules to ESLint: it checks JSX and components for common mistakes, missing keys and props validation, unsafe lifecycle methods and style choices, with recommended presets and settings that detect your React version. It works with ESLint's flat config (eslint.config.js) and the legacy .eslintrc format. MIT licensed, maintained by the jsx-eslint organization.

Problems it solves

  • catch React mistakes like missing keys in my editor before code review
  • enforce React and JSX conventions across my team's codebase
  • warn when a React component uses deprecated or unsafe lifecycle methods

Features

  • React and JSX rules for ESLint
  • recommended presets for flat config and .eslintrc
  • detects your installed React version

Alternatives

The same job

These do what eslint-plugin-react does.

  1. ESLint Find and fix problems in your JavaScript code.
  2. Airbnb JavaScript Style Guide Airbnb's JavaScript style guide and the ESLint configs that enforce it
  3. Stylelint A CSS linter that catches errors and enforces conventions in your stylesheets
  4. eslint-plugin-jsx-a11y Static AST checker for accessibility rules on JSX elements
  5. typos Source code spell checker
  6. yamllint A linter for YAML files

Compare eslint-plugin-react with the top 3