
@ariestools/eslint-config-flat

ESLint Config used throughout XY Labs TypeScript/JavaScript libraries and react projects
Install
Using npm:
npm install -D {{name}}
Using yarn:
yarn add -D {{name}}
Using pnpm:
pnpm add -D {{name}}
Using bun:
bun add -D {{name}}
Usage
Use this config in your eslint.config.ts:
import { recommendedConfig } from '@ariestools/eslint-config-flat'
const xylabsConfig = recommendedConfig({ tier: 3, isTypeChecked: true })
export default [
...xylabsConfig,
]
recommendedConfig accepts:
tier | 3 | Preset strictness level (0–4) |
isTypeChecked | true | Enable TypeScript type-checked rules |
When isTypeChecked is false, all rules that require parser type information are disabled across every tier — including opinionated promotions and React layers — and a safety-net gate turns off any type-checked preset rules that would otherwise remain active.
Tiered presets
Each tier is a superset of the previous tier. Pick the strictness level that fits your project.
| 0 | Correctness | Type safety, bug prevention, import restrictions, markdown |
| 1 | Consistency | Tier 0 + formatting, member ordering, complexity limits |
| 2 | Best practices | Tier 1 + unicorn, import validation, workspace rules |
| 3 | Opinionated | Tier 2 + unicorn v66 warnings and optional rules promoted to errors |
| 4 | Experimental | Tier 3 + unicorn v67 and v69 warnings (v66 remain warnings; canary tier) |
Rule catalog
XY-managed rule tier assignments live in RULE_CATALOG (exported from this package). The catalog records each rule's plugin, category, introducing tier, and whether it requires type checking. Tier composition is built from this catalog plus upstream plugin presets.
Named exports such as configTier3OpinionatedTypeChecked remain available but are deprecated. Prefer recommendedConfig({ tier: 3, isTypeChecked: true }).
Type-checked variants append TypeChecked (for example configTier3OpinionatedTypeChecked).
Rules introduced only at tier 3 or 4 default to warnings. New upstream plugin rules may also be held in migration queues at warning severity while consuming repos adopt them. Use xy lint --strict (or XY_STRICT=1) to treat warnings as errors in CI.
import { configTier4ExperimentalTypeChecked } from '@ariestools/eslint-config-flat'
export default [...configTier4ExperimentalTypeChecked]
config is deprecated. Use configTier3OpinionatedTypeChecked instead.
recommendedTypeCheckedConfig is a deprecated compatibility alias for configTier2BestPracticesTypeChecked.
Extending with custom rules
import { configTier3OpinionatedTypeChecked } from '@ariestools/eslint-config-flat'
const eslintConfig = [
...configTier3OpinionatedTypeChecked,
{
rules: {
},
},
]
export default eslintConfig
Individual configs
You can also import individual configs for more granular control:
import {
importConfig,
rulesConfig,
typescriptConfig,
unicornConfig,
} from '@ariestools/eslint-config-flat'
What's included
- TypeScript strict linting via
@typescript-eslint
- Import sorting and validation via
eslint-plugin-import-x
- Best practices via
eslint-plugin-unicorn
- Monorepo workspace rules via
eslint-plugin-workspaces
- Markdown linting via
eslint-plugin-markdown
- Stylistic formatting (no semicolons, single quotes, trailing commas, 2-space indent)
For React projects, use @ariestools/eslint-config-react-flat instead.
Rule ownership
Some plugins cover similar territory. This config assigns a single canonical owner per concern and disables overlapping rules. See RULE_OWNERSHIP_GROUPS and assertNoRuleOwnershipConflicts exported from this package.
When upgrading ESLint plugins, run tests in this package — spec/plugin-rules.spec.ts snapshots each plugin's rule list and fails when new rules appear.
License
See the LICENSE file for license rights and limitations (LGPL-3.0-only).
Credits
Made with 🔥 and ❄️ by XY Labs