# @egor.xyz/eslint-config

> Egor's ESLint flat config

Latest version **3.5.0** (published 2025-04-08) · MIT license · 0 weekly downloads

## Install

```sh
npm install @egor.xyz/eslint-config
pnpm add @egor.xyz/eslint-config
yarn add @egor.xyz/eslint-config
bun add @egor.xyz/eslint-config
```

## Health

**Score 45/100 (D)** — status: stable.

Positive: esm support; no vulnerabilities; high maintenance score.

Warnings: low downloads; no types.

Negative: stale.

## Facts

| | |
|---|---|
| Version | 3.5.0 |
| Published | 2025-04-08 |
| First published | 2021-07-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 7 |
| Unpacked size | 13.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Egor Stronhin |
| Maintainers | egor.xyz |
| Keywords | eslint, flat-config, plugin, linter |

## Links

- npm: https://www.npmjs.com/package/@egor.xyz/eslint-config
- Repository: https://github.com/egor-xyz/eslint-config
- Homepage: https://github.com/egor-xyz/eslint-config#readme
- Issues: https://github.com/egor-xyz/eslint-config/issues
- npm.io page: https://npm.io/package/@egor.xyz/eslint-config

## Dependencies (7)

- [@eslint/js](https://npm.io/package/@eslint/js.md) ^9.24.0
- [typescript-eslint](https://npm.io/package/typescript-eslint.md) ^8.29.1
- [eslint-plugin-react](https://npm.io/package/eslint-plugin-react.md) ^7.37.5
- [eslint-config-prettier](https://npm.io/package/eslint-config-prettier.md) ^10.1.1
- [eslint-plugin-react-hooks](https://npm.io/package/eslint-plugin-react-hooks.md) ^5.2.0
- [eslint-plugin-perfectionist](https://npm.io/package/eslint-plugin-perfectionist.md) ^4.11.0
- [eslint-plugin-react-refresh](https://npm.io/package/eslint-plugin-react-refresh.md) ^0.4.19

## Alternatives

- [eslint-plugin-sonarjs](https://npm.io/package/eslint-plugin-sonarjs.md) — 2.9M weekly downloads
- [eslint-config-expo](https://npm.io/package/eslint-config-expo.md) — 1.5M weekly downloads
- [@matter/protocol](https://npm.io/package/@matter/protocol.md) — 63.5K weekly downloads
- [@eventcatalog/linter](https://npm.io/package/@eventcatalog/linter.md) — 24.8K weekly downloads
- [@pandacss/eslint-plugin](https://npm.io/package/@pandacss/eslint-plugin.md) — 18.7K weekly downloads

## Recent versions

- 3.5.0 (latest) — 2025-04-08
- 3.4.0 — 2025-04-08
- 3.3.0 — 2025-04-08
- 3.2.0 — 2025-04-08
- 3.1.0 — 2025-04-08
- 3.0.0 — 2024-11-28
- 2.1.0 — 2024-03-12
- 2.0.0 — 2024-02-05
- 1.6.0 — 2023-06-28
- 1.5.0 — 2023-06-19
- 1.4.0 — 2023-06-19
- 1.2.0 — 2023-06-19
- 1.1.0 — 2023-06-19
- 1.0.0 — 2022-06-14
- 0.0.8 — 2021-07-15
- … 4 more at https://npm.io/package/@egor.xyz/eslint-config/versions

## README

# eslint-config

This is my [ESLint 9](https://eslint.org/) flat configuration for any Node or React project using TypeScript.

It includes all my favorite rules and helps keep codebases aligned
and in-sync with the highest standards.

### Install the package

```shell
npm i -D eslint @egor.xyz/eslint-config
```

Create an `eslint.config.mjs` file, or `eslint.config.js` if you have `type: "module"`, in the root of your project.

### React

Includes all configurations (React, TypeScript, Node, etc.)

```javascript
import config from '@egor.xyz/eslint-config';
import tseslint from 'typescript-eslint';

export default tseslint.config(
  {
    // ignore files and folders from root: node_modules, dist, build, *.js, *.ts
    ignores: ['node_modules', 'dist', 'build', '*.js', '*.ts']
  },
  {
    extends: config,
    files: ['**/*.{ts,tsx}']
  }
);
```

### Node

Node.js specific configuration, without React rules

```javascript
import configNode from '@egor.xyz/eslint-config/node.js';
import tseslint from 'typescript-eslint';

export default tseslint.config(
  {
    ignores: ['node_modules', 'dist', 'build', '*.js', '*.ts']
  },
  {
    extends: configNode,
    files: ['**/*.{ts,tsx}']
  }
);
```

### Customization

You can customize the ESLint configuration by extending it in your own configuration file. For example:

```javascript
import config from '@egor.xyz/eslint-config';
import tseslint from 'typescript-eslint';
// or import partial configs
import { configEslint } from '@egor.xyz/eslint-config/configs/config-eslint.js';
import { configTS } from '@egor.xyz/eslint-config/configs/config-ts.js';
import { configReact } from '@egor.xyz/eslint-config/configs/config-react.js';

export default tseslint.config(
  {
    ignores: ['node_modules', 'dist', 'build', '*.js', '*.ts']
  },
  {
    extends: [
      // ...
      ...config,
      // or partial configs
      ...configEslint,
      ...configTS
      // ...
    ],
    files: ['**/*.{ts,tsx}'],
    rules: {
      // Override or add your custom rules here
      'no-console': 'warn',
      'react/prop-types': 'off',
      'no-explicit-any': 'off'
    }
  }
);
```

## Development

### ESLint Config Inspector

A visual tool to help you understand and inspect ESLint flat configuration files

```shell
npm run inspect
```

### Testing

Checking for errors in the configuration file

```shell
npm test
```

---
_Source: https://npm.io/package/@egor.xyz/eslint-config · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
