LLM-Ready SQL queries on ESLint errors in your project
A powerful tool for analyzing ESLint output with SQL queries, perfect for understanding code quality patterns and planning migration strategies.
ESLint Analyzer is designed for:
- Error Analysis: Deep dive into your project's linting issues with SQL queries
- Statistics: Generate comprehensive reports on code quality metrics
- Migration Strategies: Plan ESLint adoption in large legacy projects by understanding error distribution
- Team Insights: Identify patterns and prioritize fixes across your codebase
Perfect for teams wanting to bring ESLint to existing projects or analyze code quality at scale.
The tool creates a DuckDB table with the following columns:
Column | Type | Description |
---|---|---|
file_path |
TEXT | Path to the file containing the error/warning |
rule_id |
TEXT | ESLint rule identifier (e.g., no-unused-vars ) |
project_name |
TEXT | Project name (derived from uploaded file name) |
start_line |
INTEGER | Line number where the issue starts |
end_line |
INTEGER | Line number where the issue ends |
start_column |
INTEGER | Column number where the issue starts |
end_column |
INTEGER | Column number where the issue ends |
fixable |
BOOLEAN | Whether the issue can be auto-fixed |
deprecated |
BOOLEAN | Whether the rule is deprecated |
node_type |
TEXT | AST node type where the issue occurs |
severity |
TEXT | Issue severity (error or warning ) |
# Using Docker
docker run -p 3000:3000 eslint-analyzer
# Or run locally
pnpm install
pnpm start

The application will be available at http://localhost:3000
In your project(s), generate ESLint output in JSON format:
# Single project
eslint . --format json --output-file my-project.json
# For monorepos - create separate files for each package
eslint packages/frontend --format json --output-file frontend.json
eslint packages/backend --format json --output-file backend.json
Note: The filename (without extension) becomes the
project_name
in the database.
- Open the web interface at
http://localhost:3000
- Upload your JSON file(s) using the file picker
- Optional: Enter your project's root directory name to convert absolute file paths to relative paths (removes usernames and system-specific paths)
- Click "Process" to import the data
- Multiple files can be uploaded for monorepo analysis
Here are some LLM-made practical SQL queries to analyze your ESLint data:
SELECT
severity,
COUNT(*) as count
FROM eslint
GROUP BY severity;
SELECT
file_path,
COUNT(*) as total_issues,
SUM(CASE WHEN severity = 'error' THEN 1 ELSE 0 END) as errors,
SUM(CASE WHEN severity = 'warning' THEN 1 ELSE 0 END) as warnings
FROM eslint
GROUP BY file_path
ORDER BY total_issues DESC
LIMIT 10;
SELECT
file_path,
COUNT(*) as fixable_issues
FROM eslint
WHERE fixable = true
GROUP BY file_path
HAVING COUNT(*) = (
SELECT COUNT(*)
FROM eslint e2
WHERE e2.file_path = eslint.file_path
)
ORDER BY fixable_issues DESC
LIMIT 10;
SELECT
file_path,
COUNT(*) as fixable_warnings
FROM eslint
WHERE severity = 'warning'
AND fixable = true
GROUP BY file_path
HAVING COUNT(*) = (
SELECT COUNT(*)
FROM eslint e2
WHERE e2.file_path = eslint.file_path
AND e2.severity = 'warning'
)
ORDER BY fixable_warnings DESC;
SELECT
project_name,
rule_id,
COUNT(*) as occurrences
FROM eslint
GROUP BY project_name, rule_id
ORDER BY project_name, occurrences DESC;
Just kidding, there's no contribution process! 😄
But if you find this tool useful and want to improve it, send me an email.