-
Notifications
You must be signed in to change notification settings - Fork 11
Description
Goal
Add a filter for ESLint — the dominant JavaScript/TypeScript linter used in virtually every professional JS project.
Background
On large codebases (especially during initial adoption or major version migration), ESLint can emit hundreds or thousands of warning lines before any errors. The core problem: warnings bury errors. When a file has both errors and warnings, they're interleaved. When a project has 500 warning lines and 3 error lines, finding the errors requires scrolling through all warnings.
--quiet mode suppresses all warnings entirely — losing visibility into degrading code quality. No built-in middle-ground exists for "show all errors + warning count summary only."
ESLint v9.24.0 introduced bulk suppression to address migration noise, but this requires a separate setup step and doesn't help with day-to-day output.
Filters to Add
eslint/check.toml — eslint . / eslint src/
- Skip: individual
warninglines whenerrorlines are present in the output; repetitiveeslint-disable-next-linesuggestion footnotes - Keep:
- All
errorlines (with file:line context) - A count summary of warnings (e.g. extract
X warningsfrom footer) - The final
✖ X problems (Y errors, Z warnings)summary line - All lines when there are no errors (warnings-only run)
- All
eslint/fix.toml — eslint --fix .
- Skip: unchanged file notices
- Keep: files that had errors (unfixable), summary of what was fixed
Fixture Files Needed
tests/fixtures/eslint/errors-and-warnings.txt— output with both error and warning lines mixedtests/fixtures/eslint/warnings-only.txt— only warnings, no errorstests/fixtures/eslint/errors-only.txt— only errorstests/fixtures/eslint/clean.txt— no issues found
Acceptance Criteria
- When errors exist, individual warning lines are suppressed; warning count is shown in summary
- All error lines (with file:line context) are always preserved
- When only warnings exist (no errors), all warning lines are preserved
- Final problem count summary always preserved
- Integration tests pass for all fixture files