# elindorath/eslint-plugin architecture

> Architecture diagram of the GitHub repository elindorath/eslint-plugin, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-24). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/elindorath/eslint-plugin
- Repository: https://github.com/elindorath/eslint-plugin

## Overview

This is an ESLint plugin that combines selected rule plugins into reusable configurations organized by language, source type, syntax, environment, and library. Users either select typed configurations directly or describe file groups with `defineProject`, which resolves applicable configurations. ESLint consumes the exported plugin API, including configs, rules, environments, languages, processors, and utilities. The graph shows the documented configuration workflow and sampled module links; unsampled config families are represented at their existing directory paths, and unverified wiring is omitted.

Main entry points: [`src/index.ts`](https://github.com/elindorath/eslint-plugin/blob/main/src/index.ts) (Plugin entry), [`src/configs/plugins`](https://github.com/elindorath/eslint-plugin/tree/main/src/configs/plugins) (Plugin rule bundles), [`src/configs`](https://github.com/elindorath/eslint-plugin/tree/main/src/configs) (Typed configurations), [`src/defineProject.ts`](https://github.com/elindorath/eslint-plugin/blob/main/src/defineProject.ts) (Project builder)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_api["Plugin API"]
  node_entry["Plugin entry<br/>[index.ts]"]
  node_config_exports["Config exports<br/>[configs.ts]"]
  node_metadata["Plugin metadata<br/>[meta.ts]"]
end

subgraph group_selection["Config Selection"]
  node_project["Project builder<br/>[defineProject.ts]"]
  node_registry["Axis registry<br/>[registry.ts]"]
  node_merger["Config merger<br/>[configMerger.ts]"]
  node_types["Config types<br/>[types.ts]"]
end

subgraph group_rules["Rule Configurations"]
  node_axis_configs["Typed configurations"]
  node_plugin_rules["Plugin rule bundles"]
  node_rule_eslint["JavaScript rules"]
  node_rule_perfectionist["Ordering rules"]
  node_rule_sonar["Analysis rules"]
  node_rule_stylistic["Layout rules"]
  node_rule_unicorn["JavaScript rules"]
  node_rule_tanstack["Query rules"]
end

subgraph group_runtime["Runtime Support"]
  node_processor_api["Processor exports<br/>[processors.ts]"]
  node_markdown_processor["Markdown processor<br/>[markdown.ts]"]
  node_utilities["Utilities<br/>[utilities.ts]"]
end

node_developer(("Configuration author"))
node_eslint["ESLint"]

node_developer -->|"imports plugin"| node_entry
node_entry -->|"exports plugin"| node_eslint
node_entry -->|"exports configs"| node_config_exports
node_entry -->|"exports builder"| node_project
node_entry -->|"exports processors"| node_processor_api
node_entry -->|"exports utilities"| node_utilities
node_entry -->|"exports metadata"| node_metadata
node_config_exports -->|"imports configs"| node_axis_configs
node_project -->|"selects configs"| node_registry
node_project -->|"merges configs"| node_merger
node_registry -->|"selects by axes"| node_axis_configs
node_axis_configs -->|"merges rules"| node_merger
node_axis_configs -->|"imports bundles"| node_plugin_rules
node_plugin_rules -->|"defines rules"| node_rule_eslint
node_plugin_rules -->|"defines rules"| node_rule_perfectionist
node_plugin_rules -->|"defines rules"| node_rule_sonar
node_plugin_rules -->|"defines rules"| node_rule_stylistic
node_plugin_rules -->|"defines rules"| node_rule_unicorn
node_axis_configs -->|"includes rules"| node_rule_tanstack
node_processor_api -.->|"registers processor"| node_markdown_processor
node_utilities -->|"uses rules"| node_rule_eslint

click node_entry "https://github.com/elindorath/eslint-plugin/blob/main/src/index.ts"
click node_config_exports "https://github.com/elindorath/eslint-plugin/blob/main/src/configs.ts"
click node_project "https://github.com/elindorath/eslint-plugin/blob/main/src/defineProject.ts"
click node_registry "https://github.com/elindorath/eslint-plugin/blob/main/src/registry.ts"
click node_merger "https://github.com/elindorath/eslint-plugin/blob/main/src/configMerger.ts"
click node_axis_configs "https://github.com/elindorath/eslint-plugin/tree/main/src/configs"
click node_plugin_rules "https://github.com/elindorath/eslint-plugin/tree/main/src/configs/plugins"
click node_rule_eslint "https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/eslint/language-javascript.ts"
click node_rule_perfectionist "https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/perfectionist/language-javascript.ts"
click node_rule_sonar "https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/sonarjs/language-javascript.ts"
click node_rule_stylistic "https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/stylistic/language-javascript-layout.ts"
click node_rule_unicorn "https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/unicorn/language-javascript.ts"
click node_rule_tanstack "https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/tanstack-query/library-tanstack-query.ts"
click node_processor_api "https://github.com/elindorath/eslint-plugin/blob/main/src/processors.ts"
click node_markdown_processor "https://github.com/elindorath/eslint-plugin/blob/main/src/processors/markdown.ts"
click node_utilities "https://github.com/elindorath/eslint-plugin/blob/main/src/utilities.ts"
click node_metadata "https://github.com/elindorath/eslint-plugin/blob/main/src/meta.ts"
click node_types "https://github.com/elindorath/eslint-plugin/blob/main/src/types.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_entry,node_config_exports,node_metadata toneBlue
class node_project,node_registry,node_merger,node_types toneAmber
class node_axis_configs,node_plugin_rules,node_rule_eslint,node_rule_perfectionist,node_rule_sonar,node_rule_stylistic,node_rule_unicorn,node_rule_tanstack toneMint
class node_processor_api,node_markdown_processor,node_utilities toneRose
class node_developer,node_eslint toneIndigo
```

## Components

### Plugin API

- [Plugin entry](https://github.com/elindorath/eslint-plugin/blob/main/src/index.ts): `src/index.ts`
- [Config exports](https://github.com/elindorath/eslint-plugin/blob/main/src/configs.ts): `src/configs.ts`
- [Plugin metadata](https://github.com/elindorath/eslint-plugin/blob/main/src/meta.ts): `src/meta.ts`

### Config Selection

- [Project builder](https://github.com/elindorath/eslint-plugin/blob/main/src/defineProject.ts): `src/defineProject.ts`
- [Axis registry](https://github.com/elindorath/eslint-plugin/blob/main/src/registry.ts): `src/registry.ts`
- [Config merger](https://github.com/elindorath/eslint-plugin/blob/main/src/configMerger.ts): `src/configMerger.ts`
- [Config types](https://github.com/elindorath/eslint-plugin/blob/main/src/types.ts): `src/types.ts`

### Rule Configurations

- [Typed configurations](https://github.com/elindorath/eslint-plugin/tree/main/src/configs): `src/configs`
- [Plugin rule bundles](https://github.com/elindorath/eslint-plugin/tree/main/src/configs/plugins): `src/configs/plugins`
- [JavaScript rules](https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/eslint/language-javascript.ts): `src/configs/plugins/eslint/language-javascript.ts`
- [Ordering rules](https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/perfectionist/language-javascript.ts): `src/configs/plugins/perfectionist/language-javascript.ts`
- [Analysis rules](https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/sonarjs/language-javascript.ts): `src/configs/plugins/sonarjs/language-javascript.ts`
- [Layout rules](https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/stylistic/language-javascript-layout.ts): `src/configs/plugins/stylistic/language-javascript-layout.ts`
- [JavaScript rules](https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/unicorn/language-javascript.ts): `src/configs/plugins/unicorn/language-javascript.ts`
- [Query rules](https://github.com/elindorath/eslint-plugin/blob/main/src/configs/plugins/tanstack-query/library-tanstack-query.ts): `src/configs/plugins/tanstack-query/library-tanstack-query.ts`

### Runtime Support

- [Processor exports](https://github.com/elindorath/eslint-plugin/blob/main/src/processors.ts): `src/processors.ts`
- [Markdown processor](https://github.com/elindorath/eslint-plugin/blob/main/src/processors/markdown.ts): `src/processors/markdown.ts`
- [Utilities](https://github.com/elindorath/eslint-plugin/blob/main/src/utilities.ts): `src/utilities.ts`

### Other components

- **Configuration author**
- **ESLint**

## Connections

- Configuration author → Plugin entry: imports plugin
- Plugin entry → ESLint: exports plugin (evidence: `src/index.ts`)
- Plugin entry → Config exports: exports configs (evidence: `src/index.ts`)
- Plugin entry → Project builder: exports builder (evidence: `src/index.ts`)
- Plugin entry → Processor exports: exports processors (evidence: `src/index.ts`)
- Plugin entry → Utilities: exports utilities (evidence: `src/index.ts`)
- Plugin entry → Plugin metadata: exports metadata (evidence: `src/index.ts`)
- Config exports → Typed configurations: imports configs (evidence: `src/configs.ts`)
- Project builder → Axis registry: selects configs (evidence: `src/defineProject.ts`)
- Project builder → Config merger: merges configs (evidence: `src/defineProject.ts`)
- Axis registry → Typed configurations: selects by axes (evidence: `src/registry.ts`)
- Typed configurations → Config merger: merges rules (evidence: `src/configs/language-javascript.ts`)
- Typed configurations → Plugin rule bundles: imports bundles (evidence: `src/configs/language-javascript.ts`)
- Plugin rule bundles → JavaScript rules: defines rules (evidence: `src/configs/language-javascript.ts`)
- Plugin rule bundles → Ordering rules: defines rules (evidence: `src/configs/language-javascript.ts`)
- Plugin rule bundles → Analysis rules: defines rules (evidence: `src/configs/language-javascript.ts`)
- Plugin rule bundles → Layout rules: defines rules (evidence: `src/configs/language-javascript-layout.ts`)
- Plugin rule bundles → JavaScript rules: defines rules (evidence: `src/configs/language-javascript.ts`)
- Typed configurations → Query rules: includes rules (evidence: `src/configs/library-tanstack-query.ts`)
- Processor exports → Markdown processor: registers processor
- Utilities → JavaScript rules: uses rules (evidence: `src/utilities.ts`)
