From 85b8724c73ea0423ace1b2e62d863c78bb693442 Mon Sep 17 00:00:00 2001 From: Phantom <59059173+EurFelux@users.noreply.github.com> Date: Tue, 16 Sep 2025 00:11:47 +0800 Subject: [PATCH] chore: add eslint cache to gitignore and enable cache in lint commands (#10167) Enable eslint cache to improve linting performance and add .eslintcache to gitignore --- .gitignore | 1 + package.json | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 39b5630926..fcaa2be164 100644 --- a/.gitignore +++ b/.gitignore @@ -37,6 +37,7 @@ dist out mcp_server stats.html +.eslintcache # ENV .env diff --git a/package.json b/package.json index 502775a8ba..b01cc696da 100644 --- a/package.json +++ b/package.json @@ -63,9 +63,9 @@ "test:ui": "vitest --ui", "test:watch": "vitest", "test:e2e": "yarn playwright test", - "test:lint": "oxlint --deny-warnings && eslint . --ext .js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts", + "test:lint": "oxlint --deny-warnings && eslint . --ext .js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --cache", "test:scripts": "vitest scripts", - "lint": "oxlint --fix && eslint . --ext .js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix && yarn typecheck && yarn check:i18n", + "lint": "oxlint --fix && eslint . --ext .js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --cache && yarn typecheck && yarn check:i18n", "format": "biome format --write && biome lint --write", "format:check": "biome format && biome lint", "prepare": "git config blame.ignoreRevsFile .git-blame-ignore-revs && husky",