ADR 0001: Do not adopt @eslint/plugin-kit for rule/runtime internals
- Status: Accepted
- Date: 2026-02-22
Context
The repository currently uses custom internal utilities to build and maintain rule behavior:
src/_internal/typed-rule.tsfor typed rule creation and parser service/type-checker access.src/_internal/imported-type-aliases.tsfor type import collection and safe type replacement fixes.src/_internal/imported-value-symbols.tsfor value import collection, scope-safe replacement names, and import-inserting autofix generation.
@eslint/plugin-kit (per package README) provides utilities focused on:
ConfigCommentParserDirectiveVisitNodeStep/CallMethodStepTextSourceCodeBase
These are primarily for implementing custom language/source-code plumbing (directive parsing, traversal, SourceCode-like behavior), not for rule-level import-safe fixer orchestration.
Decision
Do not adopt @eslint/plugin-kit in this plugin at this time.
Rationale
- No direct capability overlap with this repository's highest-complexity internals (typed rule services, safe import insertion, scope-safe symbol replacement).
- Would not reduce maintenance burden in currently hand-rolled areas.
- Would add dependency and migration surface without meaningful DX/perf/correctness gains.
Consequences
- Keep existing internal abstractions in
src/_internal/*. - Continue targeted hardening/tests around import-inserting autofix behavior.
Revisit Triggers
Re-evaluate adoption if we add custom language support requiring:
- custom
SourceCode#traverse()step modeling, - custom disable directive parsing/representation,
- or other infrastructure directly using
Directiveand traversal step abstractions.