ESLint Config Generator Prompt
Generate a version-compatible ESLint configuration from a supplied JavaScript or TypeScript stack, framework, module system, rule goals, and validation output.
Prompt Template
You are a senior JavaScript tooling engineer generating an ESLint configuration only from the project facts, installed versions, file types, runtime targets, and policy goals I provide. Produce the smallest maintainable configuration that fits the verified ESLint generation and plugin APIs. Treat ESLint, parsers, plugins, shareable configs, frameworks, module systems, package managers, and editors as compatibility boundaries. Never invent package versions, exported config names, rule availability, globals, parser options, framework behavior, or successful lint results. Project purpose: [web app, Node service, library, CLI, monorepo, other] Repository structure and lint scope: [paths or sanitized tree] Package manager and workspace setup: [details] Node and package module mode: [versions, ESM, CommonJS, mixed, unknown] ESLint version: [exact installed version or unknown] Existing ESLint files and migration goal: [paste sanitized content or none] Languages and file extensions: [JavaScript, TypeScript, JSX, TSX, JSON, other] Frameworks and exact versions: [details] Parser, plugins, shareable configs, and exact installed versions: [verified list] Type-aware linting requirement and tsconfig paths: [details] Runtime environments and verified globals: [browser, Node, worker, test runner, other] Generated, build, vendor, coverage, and fixture paths to ignore: [list] Formatting boundary: [ESLint only, formatter integration, unknown] Rule goals: [bugs, imports, promises, accessibility, framework rules, team conventions, other] Current lint command, editor integration, and CI behavior: [details] Known errors or warnings: [paste exact sanitized output] Performance constraints: [details] Output format: [flat config, legacy config only when required by verified versions, migration plan] Validation available: [config inspection, lint command, representative files, CI] Provide: 1. An assumptions table marking every version, package, exported preset, file pattern, parser option, global, ignore, and rule as verified, inferred, or unknown. 2. A recommendation for flat or legacy configuration based only on the supplied versions and compatibility evidence. 3. A complete configuration file with ordered blocks, explicit file scopes, justified ignores, and comments only where they prevent a likely mistake. 4. An exact dependency list separated into already installed, required after verification, optional, obsolete, and conflicting packages; do not invent install commands when versions are unknown. 5. Package scripts and editor or CI wiring that reuse one lint definition without silently fixing files in verification jobs. 6. A rule map explaining the source, scope, severity, overlap, performance cost, and reason for every non-default choice. 7. A migration note covering removed files, changed presets, compatibility checks, formatter boundaries, and rollback. 8. Test cases using representative valid and invalid files for each configured language, framework, runtime, override, ignore, and type-aware path. 9. Version-appropriate validation commands for printing or inspecting the resolved config and running lint, labeling anything that needs official-documentation verification. 10. A final audit for nonexistent exports, duplicate plugins, stale syntax, broad ignores, wrong globals, parser-project drift, formatting conflicts, type-aware performance regressions, hidden warnings, and claims not backed by actual output. Do not weaken rules merely to make lint pass, add a dependency without compatibility evidence, include proprietary source code in examples, or claim the configuration works without running validation. Ask for missing versions and error output or leave explicit placeholders rather than guessing.
Example Output
Verified Inputs
The project uses supplied current versions of ESLint, TypeScript, and one TypeScript parser package in an ESM workspace. Framework plugin versions, test globals, formatter integration, and type-aware linting requirements remain unknown.
Proposed Shape
eslint.config.js exports an ordered flat-config array with: a narrow ignore block for verified generated paths; a JavaScript block; a TypeScript block scoped to supplied extensions; and no framework, test, or formatter preset until its package and exported config are verified.
Validation Boundary
Inspect the resolved config for one JavaScript and one TypeScript file, run lint without automatic fixes, then add type-aware or framework rules only after their versions, file scopes, and performance are confirmed. Passing configuration parsing alone does not prove the rules cover the intended files.
Tips for Best Results
- ๐กProvide exact ESLint, parser, plugin, framework, Node, and module-system versions before asking for a config.
- ๐กScope language and framework blocks to explicit file patterns so globals and parser options do not leak.
- ๐กInspect the resolved config on representative files and run lint without fixes before changing severity or CI behavior.
Frequently Asked Questions
What is the ESLint Config Generator Prompt prompt?
Generate a version-compatible ESLint configuration from a supplied JavaScript or TypeScript stack, framework, module system, rule goals, and validation output. It's a free ChatGPT prompt template from our Coding collection โ copy it, fill in the bracketed variables, and paste it into your AI tool.
Which AI tools work with this prompt?
It's written and tested for ChatGPT, Claude and Gemini. Any AI assistant that accepts free-form text prompts will handle it well.
How do I customize this ChatGPT prompt?
Replace the bracketed variables โ such as [paths or sanitized tree], [details], [versions, ESM, CommonJS, mixed, unknown] โ with your own details before running it. Provide exact ESLint, parser, plugin, framework, Node, and module-system versions before asking for a config.
Is this prompt free to use?
Yes. Every prompt on PromptAtlas is free to copy, customize, and use โ no signup required.
Related Prompts
Code Review Assistant
Get a thorough, senior-level code review with actionable feedback on quality, security, performance, and best practices.
Debugging Detective
Systematically debug errors and unexpected behavior with root cause analysis and fix suggestions.
Code Refactoring Advisor
Transform messy, complex code into clean, maintainable, well-structured code with clear explanations.