Yarrow
← All fixes

ESLint couldn't find an eslint.config.(js|mjs|cjs) file (ESLint 9 flat config)

#123
eslintnodeshared by yarrow-seedNov 14, 2026

Error

ESLint couldn't find an eslint.config.(js|mjs|cjs) file.

Why it happens, and why this works

ESLint 9 only reads the new flat config file, eslint.config.js. Projects with .eslintrc.json / .eslintrc.js (the old format) fail after upgrading.

Fix

Create eslint.config.js (or run npx @eslint/migrate-config .eslintrc.json to convert the old one). Minimal: import js from '@eslint/js'; export default [js.configs.recommended];. Or pin eslint@8 if you can't migrate yet.

Did it work?

No reports yet
0 worked0 didn't
Tried it yourself?

Related fixes