Skip to content

Getting Started

Version 3 makes the smallest dependency graph the default without making the configuration verbose.

  • Node.js >=22.19.0
  • ESLint ^10.0.0
  1. Install the lean package

    bash
    pnpm add -D eslint @santi020k/eslint-config-basic

    Install the config packages required by every detected framework and optional feature:

    Terminal window
    npx @santi020k/eslint-config-basic install

    The CLI uses the project’s package manager and skips dependencies that are already declared. For React, the equivalent manual install is:

    bash
    pnpm add -D @santi020k/eslint-config-react
  2. Create the zero-config setup

    eslint.config.mjs
    import { defineConfig } from '@santi020k/eslint-config-basic'
    export default defineConfig()
  3. Run ESLint

    Terminal window
    npx eslint . --max-warnings=0

The direct call detects TypeScript, frameworks, runtime, and supported optional tooling relative to eslint.config.mjs. That remains stable when an editor starts ESLint from another working directory. Missing optional packages produce an error with the exact package name to install.

Install the full bundle when dependency footprint is less important than a single batteries-included dependency:

bash
pnpm add -D eslint @santi020k/eslint-config-full
eslint.config.mjs
export { default } from '@santi020k/eslint-config-full/recommended'
eslint.config.mjs
import { defineConfig } from '@santi020k/eslint-config-basic'
export default await defineConfig({
strict: 'ci',
typescript: 'strict'
})

Continue with Installation for package selection or the v2 to v3 migration guide for an existing project.

Add a shared script to package.json so local and CI runs allow zero warnings:

{
"scripts": {
"lint": "eslint . --max-warnings=0"
}
}

Install the Microsoft ESLint extension and let it load ESLint from your workspace. ESLint 10 always uses flat config; eslint.useFlatConfig is unnecessary and ignored for that version.

For a monorepo with package-owned configs, this setting lets the extension infer working directories from package manifests and config files:

.vscode/settings.json
{
"eslint.workingDirectories": [{ "mode": "auto" }]
}

If inference selects the wrong package, use explicit working directories for your workspace layout. Check the ESLint output channel and restart the ESLint server after changing dependencies. The config factory anchors detection to its config file; use Monorepo to choose root or package-owned configs.

This consumer workflow uses the repository’s declared pnpm version and the current Node 22 release line. Declare packageManager in your package.json, commit pnpm-lock.yaml, and verify the selected Node version against the engines of every installed framework and feature pack.

.github/workflows/lint.yml
name: Lint
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: santi020k/quality/actions/setup-pnpm@eec1701b98bcc0b76d36af288ee78a0369cd84cc # v1
with:
node-version: 22.x
- run: pnpm install --frozen-lockfile
- run: pnpm exec basic-eslint compatibility
- run: pnpm run lint

The pinned Quality setup action reads packageManager and sets up Node and pnpm. Keep your project’s type checks, tests, and build alongside this lint job. For upgrade review, follow the verification checklist.

Did this page help?

Your answer stays in this browser. Share details on GitHub to help improve the docs.