From 18e4a240d877d25a1cbbbf0d308c02a5f1d78730 Mon Sep 17 00:00:00 2001 From: Noritaka Kobayashi Date: Sat, 30 Aug 2025 00:51:53 +0900 Subject: [PATCH 1/2] refactor: remove unused import in scripts --- scripts/downloadFonts.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/downloadFonts.mjs b/scripts/downloadFonts.mjs index 6a480c750d6..30d64908a1e 100644 --- a/scripts/downloadFonts.mjs +++ b/scripts/downloadFonts.mjs @@ -3,7 +3,7 @@ */ import { exec } from 'child_process'; -import { mkdir, promises as fsPromises } from 'fs'; +import { promises as fsPromises } from 'fs'; import { dirname } from 'path'; import { promisify } from 'util'; From 364eabc090776b80cd17f10eb7da2f6c0105bf1d Mon Sep 17 00:00:00 2001 From: Noritaka Kobayashi Date: Sat, 6 Sep 2025 22:51:32 +0900 Subject: [PATCH 2/2] chore: add eslint-plugin-unused-imports --- .eslintrc | 3 ++- package.json | 1 + yarn.lock | 12 ++++++++++++ 3 files changed, 15 insertions(+), 1 deletion(-) diff --git a/.eslintrc b/.eslintrc index f8b03f98a19..30fa55fca29 100644 --- a/.eslintrc +++ b/.eslintrc @@ -2,10 +2,11 @@ "root": true, "extends": "next/core-web-vitals", "parser": "@typescript-eslint/parser", - "plugins": ["@typescript-eslint", "eslint-plugin-react-compiler"], + "plugins": ["@typescript-eslint", "eslint-plugin-react-compiler", "unused-imports"], "rules": { "no-unused-vars": "off", "@typescript-eslint/no-unused-vars": ["error", {"varsIgnorePattern": "^_"}], + "unused-imports/no-unused-imports": "error", "react-hooks/exhaustive-deps": "error", "react/no-unknown-property": ["error", {"ignore": ["meta"]}], "react-compiler/react-compiler": "error" diff --git a/package.json b/package.json index c1cd16741a8..a91ca7d038a 100644 --- a/package.json +++ b/package.json @@ -72,6 +72,7 @@ "eslint-plugin-react": "7.x", "eslint-plugin-react-compiler": "^19.0.0-beta-e552027-20250112", "eslint-plugin-react-hooks": "^0.0.0-experimental-fabef7a6b-20221215", + "eslint-plugin-unused-imports": "^1.1.5", "fs-extra": "^9.0.1", "globby": "^11.0.1", "gray-matter": "^4.0.2", diff --git a/yarn.lock b/yarn.lock index e5eecaac224..93884bb7fde 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3471,6 +3471,18 @@ eslint-plugin-react@^7.23.1: semver "^6.3.1" string.prototype.matchall "^4.0.11" +eslint-plugin-unused-imports@^1.1.5: + version "1.1.5" + resolved "https://registry.yarnpkg.com/eslint-plugin-unused-imports/-/eslint-plugin-unused-imports-1.1.5.tgz#a2b992ef0faf6c6c75c3815cc47bde76739513c2" + integrity sha512-TeV8l8zkLQrq9LBeYFCQmYVIXMjfHgdRQLw7dEZp4ZB3PeR10Y5Uif11heCsHRmhdRIYMoewr1d9ouUHLbLHew== + dependencies: + eslint-rule-composer "^0.3.0" + +eslint-rule-composer@^0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/eslint-rule-composer/-/eslint-rule-composer-0.3.0.tgz#79320c927b0c5c0d3d3d2b76c8b4a488f25bbaf9" + integrity sha512-bt+Sh8CtDmn2OajxvNO+BX7Wn4CIWMpTRm3MaiKPCQcnnlm0CS2mhui6QaoeQugs+3Kj2ESKEEGJUdVafwhiCg== + eslint-scope@^5.1.1: version "5.1.1" resolved "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz"