ADR 0002: Keep @eslint/config-helpers scoped to config authoring
- Status: Accepted
- Date: 2026-02-22
Context
This repository already uses @eslint/config-helpers in the root ESLint config:
eslint.config.mjsimportsdefineConfigandglobalIgnoresfrom@eslint/config-helpers.package.jsonincludes@eslint/config-helpersas a dev dependency.
The package is designed for authoring and composing flat config objects, not for rule implementation internals.
Decision
Continue using @eslint/config-helpers for ESLint flat config composition, and do not expand it into plugin runtime/rule internals.
Rationale
- Current usage is correct and low-risk: it improves config readability and type-friendly composition.
- No replacement value for typed rule helpers or import-safe fixer infrastructure.
- Separation of concerns: config authoring helpers should remain in config-layer code.
Consequences
- Keep
defineConfig/globalIgnoresusage in config files. - Do not refactor
src/plugin.tsorsrc/_internal/*toward config-helper APIs.
Revisit Triggers
Revisit only if ESLint introduces new config-helper APIs that materially simplify distributed plugin presets beyond current src/plugin.ts construction patterns.