# Source: https://react.dev/reference/eslint-plugin-react-hooks

# ESLint Plugin React Hooks Documentation Index

The official ESLint plugin for React which enforces the Rules of React and other best practices.

## Official Documentation

- **Main Documentation**: https://react.dev/reference/eslint-plugin-react-hooks
- **Rules of Hooks**: https://react.dev/reference/rules/rules-of-hooks
- **GitHub Repository**: https://github.com/facebook/react/tree/main/packages/eslint-plugin-react-hooks

## Quick Links

### Installation & Configuration
- Installation instructions are in README.md
- Flat config (ESLint 9+) with recommended presets
- Legacy config support (.eslintrc) for ESLint < 9

### Core Rules
- **rules-of-hooks**: Enforces the Rules of Hooks
- **exhaustive-deps**: Validates dependency arrays in effects and callbacks

### React Compiler Rules
The plugin includes additional rules for the React Compiler:
- config
- error-boundaries
- component-hook-factories
- gating
- globals
- immutability
- preserve-manual-memoization
- purity
- refs
- set-state-in-effect
- set-state-in-render
- static-components
- unsupported-syntax
- use-memo
- incompatible-library

### Configuration Options
- **additionalHooks**: Configure custom Hooks validation with exhaustive-deps rule

## Package Information

- **NPM**: https://www.npmjs.com/package/eslint-plugin-react-hooks
- **GitHub Issues**: https://github.com/facebook/react/issues
- **License**: MIT