-
-
Notifications
You must be signed in to change notification settings - Fork 28
Open
Labels
Description
Environment
ESLint version: 9.39.0
@eslint/json version: 0.13.2
Node version: v25.0.0
Yarn version: 4.10.3 (PnP)
Operating System: MacOs
Which language are you using?
json
What did you do?
Configuration (`eslint.config.ts`)
import js from "@eslint/js";
import globals from "globals";
import tseslint from "typescript-eslint";
import json from "@eslint/json";
import markdown from "@eslint/markdown";
import { defineConfig } from "eslint/config";
export default defineConfig([
{
ignores: [
"dist/",
"coverage/",
"node_modules/",
".yarn/",
".git/",
],
},
{
files: ["**/*.{js,mjs,cjs,ts,mts,cts}"],
plugins: { js },
extends: ["js/recommended"],
languageOptions: {
globals: globals.node,
ecmaVersion: 2024,
sourceType: "module",
},
rules: {
semi: "error",
"prefer-const": "error",
"no-console": "warn",
"no-debugger": "error",
},
},
...tseslint.configs.recommended,
{
files: ["**/*.json"],
ignores: ["package-lock.json"],
plugins: { json },
language: "json/json",
extends: ["json/recommended"],
},
{
files: ["**/*.jsonc"],
plugins: { json },
language: "json/jsonc",
extends: ["json/recommended"],
},
{
files: ["**/*.json5"],
plugins: { json },
language: "json/json5",
extends: ["json/recommended"],
},
{
files: ["**/*.md"],
plugins: { markdown },
language: "markdown/gfm",
extends: ["markdown/recommended"],
},
]);
What did you expect to happen?
Just work because it's a vanilla config file generated using command yarn create @eslint/config
What actually happened?
An exception is thrown:
Oops! Something went wrong! :(
ESLint: 9.39.0
TypeError: Plugin config "recommended" not found in plugin "json".
at findPluginConfig (~/.yarn/berry/cache/@eslint-config-helpers-npm-0.4.2-a55655f805-10c0.zip/node_modules/@eslint/config-helpers/dist/cjs/index.cjs:296:8)
at ~/.yarn/berry/cache/@eslint-config-helpers-npm-0.4.2-a55655f805-10c0.zip/node_modules/@eslint/config-helpers/dist/cjs/index.cjs:430:25
at Array.map (<anonymous>)
at processExtends (~/.yarn/berry/cache/@eslint-config-helpers-npm-0.4.2-a55655f805-10c0.zip/node_modules/@eslint/config-helpers/dist/cjs/index.cjs:428:36)
at ~/.yarn/berry/cache/@eslint-config-helpers-npm-0.4.2-a55655f805-10c0.zip/node_modules/@eslint/config-helpers/dist/cjs/index.cjs:504:38
at Array.flatMap (<anonymous>)
at processConfigList (~/.yarn/berry/cache/@eslint-config-helpers-npm-0.4.2-a55655f805-10c0.zip/node_modules/@eslint/config-helpers/dist/cjs/index.cjs:504:20)
at defineConfig (~/.yarn/berry/cache/@eslint-config-helpers-npm-0.4.2-a55655f805-10c0.zip/node_modules/@eslint/config-helpers/dist/cjs/index.cjs:540:9)
at PROJECT_DIR/eslint.config.ts:8:26
at async Function.import (~/.yarn/berry/cache/jiti-npm-2.6.1-597ab7fb84-10c0.zip/node_modules/jiti/dist/jiti.cjs:1:158301)
Link to Minimal Reproducible Example
https://stackblitz.com/edit/nestjs-typescript-starter-hqsgwkiv
Participation
- I am willing to submit a pull request for this issue.
Additional comments
No response
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
Triaging