From 59a6e535204a053e17f197e680876e4aa7b0271e Mon Sep 17 00:00:00 2001 From: Remco Haszing Date: Wed, 14 Aug 2024 14:18:34 +0200 Subject: [PATCH] Fix ESLint config MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit You shouldn’t pass globs to ESLint. Instead, it should receive `.` (or no positional arguments starting with ESLint 9), and additional extensions should be configured with overrides in the configuration files. Now all JavaScript and TypeScript files in the repository are linted. --- .eslintrc.json | 9 +++++++-- package.json | 2 +- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index 41f516b..d5f31bf 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -27,5 +27,10 @@ "no-unused-expressions": "warn", "no-duplicate-imports": "warn", "new-parens": "warn" - } -} \ No newline at end of file + }, + "overrides": [ + { + "files": ["*.ts"] + } + ] +} diff --git a/package.json b/package.json index 6536a20..bce5aad 100644 --- a/package.json +++ b/package.json @@ -32,6 +32,6 @@ "clean": "rimraf lib", "watch": "tsc -w -p ./src", "test": "npm run compile && mocha ./lib/umd/test", - "lint": "eslint src/**/*.ts" + "lint": "eslint ." } }