{"id":19892,"library":"eslint-plugin-react-debug","title":"eslint-plugin-react-debug","description":"An ESLint plugin that provides debugging-related rules for React, part of the eslint-react monorepo. Current stable version is 4.2.3, but the latest releases are beta versions (5.5.1-beta.0 as of April 2026). It requires ESLint ^10.0.0 and TypeScript, and Node.js >=22.0.0. The plugin ships TypeScript types and is designed to help debug React components, focusing on rules that catch common mistakes and anti-patterns during development. It differentiates from other React ESLint plugins by being specifically tailored for debugging scenarios within the eslint-react ecosystem.","status":"active","version":"4.2.3","language":"javascript","source_language":"en","source_url":"https://github.com/Rel1cx/eslint-react","tags":["javascript","react","debug","eslint","eslint-react","eslint-plugin","eslint-plugin-react-debug","typescript"],"install":[{"cmd":"npm install eslint-plugin-react-debug","lang":"bash","label":"npm"},{"cmd":"yarn add eslint-plugin-react-debug","lang":"bash","label":"yarn"},{"cmd":"pnpm add eslint-plugin-react-debug","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Peer dependency required to run as an ESLint plugin","package":"eslint","optional":false},{"reason":"Required for type checking and rule analysis","package":"typescript","optional":true}],"imports":[{"note":"ESM-only; CJS require() fails in Node >=22 with default package type.","wrong":"const plugin = require('eslint-plugin-react-debug')","symbol":"default","correct":"import plugin from 'eslint-plugin-react-debug'"},{"note":"Named export for rule definitions.","wrong":null,"symbol":"rules","correct":"import { rules } from 'eslint-plugin-react-debug'"},{"note":"Configurations are exported as named export, not a separate module.","wrong":"import configs from 'eslint-plugin-react-debug/configs'","symbol":"configs","correct":"import { configs } from 'eslint-plugin-react-debug'"}],"quickstart":{"code":"import debugPlugin from 'eslint-plugin-react-debug';\nimport reactPlugin from 'eslint-plugin-react-x';\nimport tsParser from '@typescript-eslint/parser';\n\nexport default [\n  {\n    files: ['**/*.{ts,tsx}'],\n    languageOptions: {\n      parser: tsParser,\n      parserOptions: {\n        ecmaFeatures: { jsx: true },\n      },\n    },\n    plugins: {\n      'react-debug': debugPlugin,\n      'react-x': reactPlugin,\n    },\n    rules: {\n      'react-debug/rule-name': 'warn',\n      'react-x/no-set-state': 'error',\n    },\n  },\n];","lang":"typescript","description":"Configures ESLint with eslint-plugin-react-debug and eslint-plugin-react-x, enabling debugging and React X rules for TypeScript/TSX files."},"warnings":[{"fix":"Update Node.js to version 22 or higher.","message":"Requires Node.js >=22.0.0","severity":"breaking","affected_versions":">=4.2.3"},{"fix":"Update ESLint to version 10.0.0 or higher.","message":"Requires ESLint ^10.0.0","severity":"breaking","affected_versions":">=4.2.3"},{"fix":"Use import statement instead of require().","message":"Plugin uses ESM only; CommonJS require() will fail.","severity":"gotcha","affected_versions":">=4.2.3"},{"fix":"Migrate to v5 beta once stable or stay on v4.","message":"The v5 beta series introduces breaking changes; stable v4 may be deprecated after v5 release.","severity":"deprecated","affected_versions":"<5.0.0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"Run 'npm install eslint-plugin-react-debug --save-dev' or verify import path.","cause":"Missing dependency in package.json or incorrect import path.","error":"Cannot find module 'eslint-plugin-react-debug'"},{"fix":"Ensure plugins are provided as an object with plugin names as keys, e.g., 'plugins: { \"react-debug\": debugPlugin }'.","cause":"Using old ESLint flat config format incorrectly for plugins.","error":"Error: ESLint configuration in 'your-file' is invalid: \"plugins\" field must be an array or an object"},{"fix":"Check the available rules list in the plugin's documentation or refer to configurations.","cause":"Rule name does not exist in the plugin.","error":"TypeError: Cannot read properties of undefined (reading 'someRule')"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}