Preset selection strategy
This guide helps teams pick a preset based on migration tolerance, strictness goals, and rollout velocity.
No type-aware rules. All
eslint-plugin-tsconfigrules operate on thetsconfig.jsonfile structure usingjsonc-eslint-parser. None of the rules require TypeScript type services at lint time.
Decision checkpointsโ
Use these checkpoints before choosing a preset:
- Migration bandwidth: Can the team handle broad replacement churn this quarter?
- Runtime sensitivity: Do you need to review behavior-sensitive changes manually before broad adoption?
- Convergence target: Do you intend to land on
strict/all, or stay at a stable baseline? - Specialization: Does the codebase have a particular focus โ module resolution, emit, project references โ that warrants a domain preset?
Baseline presetsโ
Choose one baseline preset as the foundation. These are ordered from least to most churn.
recommendedโ
Choose this when:
- You want a pragmatic starting point for most TypeScript codebases.
- You want to pick up the highest-impact rules with minimal configuration effort.
- You can absorb moderate migration churn.
strictโ
Choose this when:
- Your codebase already enforces strong lint and type discipline.
- You prefer broader consistency constraints and can absorb more churn.
strictestโ
Choose this when:
- You want the highest confidence in tsconfig correctness.
- You are comfortable with every rule the plugin offers in the strict tier.
allโ
Choose this when:
- You want full plugin coverage across every domain and strictness level.
- You actively maintain migration and suppression hygiene.
- You are evaluating the complete rule set before narrowing down.
jsconfigโ
Choose this when:
- The project uses JavaScript with
allowJs: true/checkJs: true. - You want rules tuned for JS-first workflows rather than strict TypeScript projects.
Domain presetsโ
Layer one or more domain presets on top of a baseline when they match your codebase goals. These are additive โ you can combine multiple domain presets in a single config.
strict-modeโ
Choose this when:
- You want to enforce all TypeScript strict-mode flags as a group.
- You are converging on
"strict": trueas a team standard.
emit-configโ
Choose this when:
- Your project emits declarations, source maps, or build artifacts.
- You want rules that catch common emit misconfiguration.
module-resolutionโ
Choose this when:
- The project uses modern module resolution (
Bundler,NodeNext, etc.). - You want to catch legacy resolution patterns before they cause runtime surprises.
lib-targetโ
Choose this when:
- You want to enforce consistent
targetandlibchoices. - You want to prevent deprecated or overly broad target values.
include-hygieneโ
Choose this when:
- You want to keep
include,exclude, androotDirclean. - You want to catch common file-scoping mistakes that affect coverage or IDE behavior.
project-referencesโ
Choose this when:
- The project uses TypeScript project references (
referencesarray,composite: true). - You want rules that enforce correct reference and build configuration.
Rollout playbookโ
- Start with
warnfor one target folder/package. - Record baseline violations and identify high-churn rule families.
- Run autofix in scoped batches, then run full tests/typecheck.
- Promote to
errorafter each batch reaches zero violations. - Repeat until all target folders are converged.
Validation gatesโ
npm run lintnpm run typechecknpm run test
For monorepos, run package-level gates first, then full-repo gates.
Escalation policyโ
If a rule creates migration risk or noisy output:
- Keep the preset enabled.
- Temporarily lower that single rule to
warnoroffwith a tracking note. - Re-enable after targeted remediation.
This preserves preset consistency while avoiding long-lived blind spots.