From bac8032c471a34fb5a1ebe5921380a7d48b2cc69 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristj=C3=A1n=20Oddsson?= Date: Tue, 11 Oct 2022 12:35:48 +0200 Subject: [PATCH 1/4] Update eslint-plugin-escompat --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index edb83f19..12cc3c3a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,7 +12,7 @@ "@typescript-eslint/eslint-plugin": "^5.1.0", "@typescript-eslint/parser": "^5.1.0", "eslint-config-prettier": ">=8.0.0", - "eslint-plugin-escompat": "^3.1.0", + "eslint-plugin-escompat": "^3.3.0", "eslint-plugin-eslint-comments": "^3.2.0", "eslint-plugin-filenames": "^1.3.2", "eslint-plugin-i18n-text": "^1.0.1", @@ -1148,9 +1148,9 @@ } }, "node_modules/eslint-plugin-escompat": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-escompat/-/eslint-plugin-escompat-3.2.0.tgz", - "integrity": "sha512-obXAKKiZE/wB2fgIw0ZxCmp+8vpDsUw2inkaok1i7OVxY4cEds4Y9YCoky0f5V+q8rqZpTUJDv1R9ykWbXLX8Q==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-escompat/-/eslint-plugin-escompat-3.3.0.tgz", + "integrity": "sha512-l2OARVmcMI5PAb4KTETb+7kE2oo0Gh0TUBB7nmwi89OVSJZDmYnpDL4a5a2AzKZErss+mWecgmKncPA48JictQ==", "dependencies": { "browserslist": "^4.21.0" }, @@ -4226,9 +4226,9 @@ } }, "eslint-plugin-escompat": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-escompat/-/eslint-plugin-escompat-3.2.0.tgz", - "integrity": "sha512-obXAKKiZE/wB2fgIw0ZxCmp+8vpDsUw2inkaok1i7OVxY4cEds4Y9YCoky0f5V+q8rqZpTUJDv1R9ykWbXLX8Q==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-escompat/-/eslint-plugin-escompat-3.3.0.tgz", + "integrity": "sha512-l2OARVmcMI5PAb4KTETb+7kE2oo0Gh0TUBB7nmwi89OVSJZDmYnpDL4a5a2AzKZErss+mWecgmKncPA48JictQ==", "requires": { "browserslist": "^4.21.0" } diff --git a/package.json b/package.json index 5f9f9e36..f348e248 100644 --- a/package.json +++ b/package.json @@ -28,7 +28,7 @@ "@typescript-eslint/eslint-plugin": "^5.1.0", "@typescript-eslint/parser": "^5.1.0", "eslint-config-prettier": ">=8.0.0", - "eslint-plugin-escompat": "^3.1.0", + "eslint-plugin-escompat": "^3.3.0", "eslint-plugin-eslint-comments": "^3.2.0", "eslint-plugin-filenames": "^1.3.2", "eslint-plugin-i18n-text": "^1.0.1", From 3130f16156e5586057f1f19a6200c5839625fa5f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristj=C3=A1n=20Oddsson?= Date: Tue, 11 Oct 2022 12:37:52 +0200 Subject: [PATCH 2/4] Move typescript config into typescript config --- lib/configs/browser.js | 2 +- lib/configs/typescript.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/configs/browser.js b/lib/configs/browser.js index 11634c3b..c4afa7d6 100644 --- a/lib/configs/browser.js +++ b/lib/configs/browser.js @@ -3,7 +3,7 @@ module.exports = { browser: true }, plugins: ['github', 'escompat'], - extends: ['plugin:escompat/recommended', 'plugin:escompat/typescript'], + extends: ['plugin:escompat/recommended'], rules: { 'escompat/no-dynamic-imports': 'off', 'github/async-currenttarget': 'error', diff --git a/lib/configs/typescript.js b/lib/configs/typescript.js index 751f0145..05c2fdc4 100644 --- a/lib/configs/typescript.js +++ b/lib/configs/typescript.js @@ -1,5 +1,5 @@ module.exports = { - extends: ['plugin:@typescript-eslint/recommended', 'prettier'], + extends: ['plugin:@typescript-eslint/recommended', 'prettier', 'plugin:escompat/typescript-2020'], parser: '@typescript-eslint/parser', plugins: ['@typescript-eslint', 'github'], rules: { From 7ce64e9c0d9e93094d2d35818d0b4ed0d31c25cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristj=C3=A1n=20Oddsson?= Date: Tue, 11 Oct 2022 12:38:08 +0200 Subject: [PATCH 3/4] Install and use `@github/browserslist-config` --- package-lock.json | 11 +++++++++++ package.json | 2 ++ 2 files changed, 13 insertions(+) diff --git a/package-lock.json b/package-lock.json index 12cc3c3a..5b3f0918 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,6 +9,7 @@ "version": "0.0.0-dev", "license": "MIT", "dependencies": { + "@github/browserslist-config": "^1.0.0", "@typescript-eslint/eslint-plugin": "^5.1.0", "@typescript-eslint/parser": "^5.1.0", "eslint-config-prettier": ">=8.0.0", @@ -84,6 +85,11 @@ "url": "https://opencollective.com/eslint" } }, + "node_modules/@github/browserslist-config": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@github/browserslist-config/-/browserslist-config-1.0.0.tgz", + "integrity": "sha512-gIhjdJp/c2beaIWWIlsXdqXVRUz3r2BxBCpfz/F3JXHvSAQ1paMYjLH+maEATtENg+k5eLV7gA+9yPp762ieuw==" + }, "node_modules/@github/prettier-config": { "version": "0.0.4", "resolved": "https://registry.npmjs.org/@github/prettier-config/-/prettier-config-0.0.4.tgz", @@ -3446,6 +3452,11 @@ "strip-json-comments": "^3.1.1" } }, + "@github/browserslist-config": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@github/browserslist-config/-/browserslist-config-1.0.0.tgz", + "integrity": "sha512-gIhjdJp/c2beaIWWIlsXdqXVRUz3r2BxBCpfz/F3JXHvSAQ1paMYjLH+maEATtENg+k5eLV7gA+9yPp762ieuw==" + }, "@github/prettier-config": { "version": "0.0.4", "resolved": "https://registry.npmjs.org/@github/prettier-config/-/prettier-config-0.0.4.tgz", diff --git a/package.json b/package.json index f348e248..975a5afe 100644 --- a/package.json +++ b/package.json @@ -25,6 +25,7 @@ }, "homepage": "https://github.com/github/eslint-plugin-github#readme", "dependencies": { + "@github/browserslist-config": "^1.0.0", "@typescript-eslint/eslint-plugin": "^5.1.0", "@typescript-eslint/parser": "^5.1.0", "eslint-config-prettier": ">=8.0.0", @@ -42,6 +43,7 @@ "svg-element-attributes": "^1.3.1" }, "prettier": "@github/prettier-config", + "browserslist": "@github/browserslist-config", "peerDependencies": { "eslint": "^8.0.1" }, From 22e10aeaa2c2f1337e7322c1e93312e11ee20de1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristj=C3=A1n=20Oddsson?= Date: Tue, 11 Oct 2022 13:15:04 +0200 Subject: [PATCH 4/4] Update esling-plugin-escompat again --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 5b3f0918..33d26107 100644 --- a/package-lock.json +++ b/package-lock.json @@ -13,7 +13,7 @@ "@typescript-eslint/eslint-plugin": "^5.1.0", "@typescript-eslint/parser": "^5.1.0", "eslint-config-prettier": ">=8.0.0", - "eslint-plugin-escompat": "^3.3.0", + "eslint-plugin-escompat": "^3.3.3", "eslint-plugin-eslint-comments": "^3.2.0", "eslint-plugin-filenames": "^1.3.2", "eslint-plugin-i18n-text": "^1.0.1", @@ -1154,9 +1154,9 @@ } }, "node_modules/eslint-plugin-escompat": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-escompat/-/eslint-plugin-escompat-3.3.0.tgz", - "integrity": "sha512-l2OARVmcMI5PAb4KTETb+7kE2oo0Gh0TUBB7nmwi89OVSJZDmYnpDL4a5a2AzKZErss+mWecgmKncPA48JictQ==", + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/eslint-plugin-escompat/-/eslint-plugin-escompat-3.3.3.tgz", + "integrity": "sha512-rB3t15s0d504y3kwHotSt3wkFQG/dhS6SS5DIKL86mPILzoMcYeFN+hWim+Au7nvXGtkR1dOuq2sU5qKlOKhkA==", "dependencies": { "browserslist": "^4.21.0" }, @@ -4237,9 +4237,9 @@ } }, "eslint-plugin-escompat": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-escompat/-/eslint-plugin-escompat-3.3.0.tgz", - "integrity": "sha512-l2OARVmcMI5PAb4KTETb+7kE2oo0Gh0TUBB7nmwi89OVSJZDmYnpDL4a5a2AzKZErss+mWecgmKncPA48JictQ==", + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/eslint-plugin-escompat/-/eslint-plugin-escompat-3.3.3.tgz", + "integrity": "sha512-rB3t15s0d504y3kwHotSt3wkFQG/dhS6SS5DIKL86mPILzoMcYeFN+hWim+Au7nvXGtkR1dOuq2sU5qKlOKhkA==", "requires": { "browserslist": "^4.21.0" } diff --git a/package.json b/package.json index 975a5afe..f5374fc5 100644 --- a/package.json +++ b/package.json @@ -29,7 +29,7 @@ "@typescript-eslint/eslint-plugin": "^5.1.0", "@typescript-eslint/parser": "^5.1.0", "eslint-config-prettier": ">=8.0.0", - "eslint-plugin-escompat": "^3.3.0", + "eslint-plugin-escompat": "^3.3.3", "eslint-plugin-eslint-comments": "^3.2.0", "eslint-plugin-filenames": "^1.3.2", "eslint-plugin-i18n-text": "^1.0.1",