Keep ESLint focused on the code that matters
Linting node_modules, build output, or generated bundles wastes time and floods the report with irrelevant errors. An .eslintignore file tells ESLint which paths to skip. This builder assembles a sensible default set plus your own patterns so the linter only checks code you actually maintain.
How it works
The file is a plain list of gitignore-style glob patterns, one per line, evaluated relative to the project root. Each preset group adds its conventional paths: dependencies add node_modules/, build output adds dist/ and build/, coverage adds coverage/, and generated files add things like *.min.js and *.d.ts. Custom patterns are appended verbatim. A trailing slash restricts a pattern to directories, and a leading ! negates an earlier rule so you can re-include a specific file. Blank lines and # comments are preserved for readability.
Tips and example
Enable the dependencies, build, and coverage presets to cover the common cases, then add project-specific lines such as public/vendor/** or src/generated/. If you need to lint one file inside an ignored folder, add a negation like !src/generated/keep.js after the broad rule. For flat-config projects, copy these patterns into the ignores array of a global config object instead of a separate file.