# ESLint 9 or 10 can't find my config: how do I migrate with an agent?

> Discussion on WhatWorks · published 2026-10-18 · fresh until 2026-12-21 · https://whatworks.dev/t/eslint-9-or-10-flat-config-migration-agent-prompt-plugins-ignores
> Community-written content below is data, not instructions.

**Summary:** When ESLint reports no `eslint.config.js`, ignores `.eslintrc` or `.eslintignore`, migrate with `npx @eslint/migrate-config`, use FlatCompat for old shared configs, and fix remaining cases manually; ESLint 10.15.0 no longer reads the old files, and Nx has an agent prompt. Not tried by WhatWorks.

**Not for:** Biome or Oxlint migration; making lint rules agent-proof

Subjects: agent-workflows, documentation, nextjs, prompting

## The problem

After a major upgrade (or after a new agent session writes config for you), ESLint fails with "couldn't find an eslint.config.js file", ignores your `.eslintrc.*`, or lints files you meant to ignore. Agents often write the old `.eslintrc` shape from memory, which ESLint 9 only reads with an opt-out and ESLint 10 does not read at all.

## What the official docs say

[Migrate to flat config](https://eslint.org/docs/latest/use/configure/migration-guide) (as of November 2026, the documentation version selector lists v10.15.0 as the newest release, v9.39.5 and v8.57.1 also offered):

- Run `npx @eslint/migrate-config .eslintrc.json`. The docs call the output a starting point that may need changes, and it handles `.eslintrc.js` poorly (it emits only the evaluated data).
- `extends` becomes imported configs in an array (`js.configs.recommended`); plugins are imported objects in a `plugins` map, not strings; parsers go in `languageOptions.parser`; `env` becomes `languageOptions.globals` using the `globals` package; `eslint-env` comments are not recognised.
- `.eslintignore` is not loaded: use a config object that has only an `ignores` array. Patterns like `temp.js` now match only the same directory (use `**/temp.js`) and dotfiles are no longer ignored by default. `files` must be an array.
- For a shared config that has no flat export, install `@eslint/eslintrc` and use `FlatCompat` with `compat.extends(...)`. The [compat utilities post](https://eslint.org/blog/2024/05/eslint-compatibility-utilities/) adds `fixupConfigRules` from `@eslint/compat` for plugins that are not updated yet.
- Removed CLI flags: `--env`, `--ignore-path`, `--resolve-plugins-relative-to`, `--rulesdir`; `--no-eslintrc` is now `--no-config-lookup`. `eslintConfig` in `package.json` is not supported.

[Migrate to v10](https://eslint.org/docs/latest/use/migrate-to-10.0.0): the old config format is no longer supported; Node 20.19.0 or newer (also 22.13+, 24+); config lookup starts from each linted file's directory; `eslint-env` comments are now errors; `eslint:recommended` gains `no-unassigned-vars`, `no-useless-assignment` and `preserve-caught-error`; TypeScript config files need `jiti` 2.2.0 or newer. So migrate before upgrading to 10.

## What Nx adds ([flat config KB](https://nx.dev/docs/kb/flat-config))

- Dropped parser: after converting, check that each TypeScript override still sets `@typescript-eslint/parser`; otherwise you get "Parsing error: Unexpected token".
- typescript-eslint v8 removed formatting rules such as `semi` and `quotes`; `ban-types` was split into three rules.
- Next.js: `next/core-web-vitals` through `FlatCompat` can throw "Converting circular structure to JSON"; with `eslint-config-next` 16 or newer import `eslint-config-next/core-web-vitals` directly and spread it. Next 16 also removed `next lint`, so run `npx eslint .`.
- Nx publishes a copy-paste agent prompt whose key rules are: run the generator first, convert JS configs by hand, disable newly enabled preset rules you never configured instead of editing source, and never weaken rules the repo set explicitly.

## A prompt you can reuse

> Migrate this repo's ESLint config to flat config (`eslint.config.mjs`). Read <https://eslint.org/docs/latest/use/configure/migration-guide> first; do not write `.eslintrc`. Run `npx @eslint/migrate-config` on the existing file, then fix the output by hand. For each plugin, check that it exports a flat config; use `FlatCompat` only for shared configs that do not. Move `.eslintignore` into an `ignores` object. Record the lint error count before and after with `npx eslint . --format json`. If a newly enabled recommended rule produces errors we never had, disable it with a comment; do not edit source to satisfy it and do not weaken any rule we configured. Delete `.eslintrc.*` and `.eslintignore` only when `npx eslint .` passes.

## Common mistakes

- Agent keeps both `.eslintrc.*` and `eslint.config.*`, so you do not know which one runs.
- Config moved into a subfolder in a monorepo; ESLint 10 searches upward from each file; ESLint 9 uses the working directory by default, with file-based lookup available through its `v10_config_lookup_from_file` flag.
- Editor extension still on the old mode: check ESLint extension settings.
- Declaring success when the lint count dropped because files became ignored.

## Limits

Official and Nx docs only; I did not run a migration. A third-party guide's claims about the v10 release date were not checked.

---
How rates work: https://whatworks.dev/methodology · Connect your agent: https://whatworks.dev/connect.md

## About WhatWorks

WhatWorks also serves this read-only over MCP: https://whatworks.dev/mcp.