- ESLint v9 (flat config)
- eslint-config-next v16.2.1 — includes Core Web Vitals and TypeScript presets
The ESLint configuration lives in eslint.config.mjs and uses the flat-config format introduced in ESLint v9.
| Preset | Purpose |
|---|---|
eslint-config-next/core-web-vitals |
Next.js rules + Core Web Vitals best practices |
eslint-config-next/typescript |
TypeScript-specific rules for Next.js projects |
Defined via globalIgnores:
.next/**out/**build/**next-env.d.ts
| Rule | Reason |
|---|---|
react/no-unescaped-entities |
Allows ' and " in JSX text |
@typescript-eslint/no-unused-vars |
Permits unused variables during development |
@typescript-eslint/no-explicit-any |
Allows any type usage |
@typescript-eslint/no-empty-object-type |
Allows empty object types ({}) |
@typescript-eslint/no-empty-interface |
Allows empty interfaces |
The lint script in package.json runs ESLint:
"lint": "eslint"For a basic run use pnpm lint. When you need to pass extra flags or paths, use pnpm eslint directly — pnpm's -- separator doesn't forward args cleanly to the underlying command.
pnpm lintpnpm eslint src/components/
pnpm eslint src/app/page.tsxpnpm eslint --fix
pnpm eslint --fix src/components/