From 0b4aa6551b5bf8972416116be212bcb10675a52c Mon Sep 17 00:00:00 2001 From: dayo09 Date: Fri, 2 Sep 2022 14:27:04 +0900 Subject: [PATCH] [lint] Add envs and globals This commit adds envs and globals to configurations to remove wrong errors. NOTE "node" in "env" <-- Removes 'process' is undefined error "mocha" in "env" <-- Removes 'test'/'suites' is undefined error "Thenable" in "globals" <-- Removes 'Thenables' is undefined error. Thenable is defined in node_modules/@types/vscode "NodeJS" in "gloabls" <-- Removes 'NodeJS' is undefined error. Ref https://github.com/Chatie/eslint-config/issues/45 ONE-vscode-DCO-1.0-Signed-off-by: dayo09 --- .eslintrc.json | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.eslintrc.json b/.eslintrc.json index 5107e799..6ea53010 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -8,6 +8,15 @@ "plugins": [ "@typescript-eslint" ], + "env": { + "node": true, + "mocha": true + }, + "globals": + { + "Thenable": true, + "NodeJS": true + }, "rules": { "@typescript-eslint/naming-convention": "warn", "@typescript-eslint/semi": "warn",