From 587a0321b6f0892e7f38df7c8ab0c7a446a041b0 Mon Sep 17 00:00:00 2001 From: Daniel Rentz Date: Mon, 2 Jan 2023 06:56:04 +0100 Subject: [PATCH 1/2] disable core rule "no-unused-vars" Same problem as in https://github.com/ota-meshi/eslint-plugin-yml/issues/204, same fix as in https://github.com/ota-meshi/eslint-plugin-yml/issues/205 example.jsonc ```json /* global test */ "data" ``` triggers `1:11 error 'test' is defined but never used. Allowed unused vars must match /^_/u no-unused-vars` --- lib/configs/base.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/configs/base.ts b/lib/configs/base.ts index 7f3ff59d..1df91087 100644 --- a/lib/configs/base.ts +++ b/lib/configs/base.ts @@ -8,6 +8,7 @@ export = { // ESLint core rules known to cause problems with JSON. strict: "off", "no-unused-expressions": "off", + "no-unused-vars": "off", }, }, ], From cfcd012638bce9dba26cdbc56bb5b0de1a5e1bac Mon Sep 17 00:00:00 2001 From: Yosuke Ota Date: Thu, 5 Jan 2023 10:52:06 +0900 Subject: [PATCH 2/2] Create smart-bottles-beam.md --- .changeset/smart-bottles-beam.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/smart-bottles-beam.md diff --git a/.changeset/smart-bottles-beam.md b/.changeset/smart-bottles-beam.md new file mode 100644 index 00000000..75581a88 --- /dev/null +++ b/.changeset/smart-bottles-beam.md @@ -0,0 +1,5 @@ +--- +"eslint-plugin-jsonc": minor +--- + +disable `no-unused-vars` in base config