From 2921d53a058d0c519f6b547b7b4f1ca80a89ee42 Mon Sep 17 00:00:00 2001 From: Simon Lamon <32477463+silamon@users.noreply.github.com> Date: Wed, 2 Oct 2024 08:41:48 +0000 Subject: [PATCH 1/7] Flat config file --- .eslintrc.json | 130 ------------------ build-scripts/.eslintrc.json | 12 -- build-scripts/eslint.config.mjs | 16 +++ eslint.config.mjs | 146 ++++++++++++++++++++ gallery/.eslintrc.json | 6 - gallery/eslint.config.mjs | 10 ++ package.json | 9 +- yarn.lock | 229 +++++++++++++++++--------------- 8 files changed, 301 insertions(+), 257 deletions(-) delete mode 100644 .eslintrc.json delete mode 100644 build-scripts/.eslintrc.json create mode 100644 build-scripts/eslint.config.mjs create mode 100644 eslint.config.mjs delete mode 100644 gallery/.eslintrc.json create mode 100644 gallery/eslint.config.mjs diff --git a/.eslintrc.json b/.eslintrc.json deleted file mode 100644 index 92943aa598ed..000000000000 --- a/.eslintrc.json +++ /dev/null @@ -1,130 +0,0 @@ -{ - "extends": [ - "airbnb-base", - "airbnb-typescript/base", - "plugin:@typescript-eslint/recommended", - "plugin:wc/recommended", - "plugin:lit/all", - "plugin:lit-a11y/recommended", - "prettier" - ], - "parser": "@typescript-eslint/parser", - "parserOptions": { - "ecmaVersion": 2020, - "ecmaFeatures": { - "modules": true - }, - "sourceType": "module", - "project": "./tsconfig.json" - }, - "settings": { - "import/resolver": { - "webpack": { - "config": "./webpack.config.cjs" - } - } - }, - "globals": { - "__DEV__": false, - "__DEMO__": false, - "__BUILD__": false, - "__VERSION__": false, - "__STATIC_PATH__": false, - "__SUPERVISOR__": false, - "Polymer": true - }, - "env": { - "browser": true, - "es6": true - }, - "rules": { - "class-methods-use-this": "off", - "new-cap": "off", - "prefer-template": "off", - "object-shorthand": "off", - "func-names": "off", - "no-underscore-dangle": "off", - "strict": "off", - "no-plusplus": "off", - "no-bitwise": "error", - "comma-dangle": "off", - "vars-on-top": "off", - "no-continue": "off", - "no-param-reassign": "off", - "no-multi-assign": "off", - "no-console": "error", - "radix": "off", - "no-alert": "off", - "no-nested-ternary": "off", - "prefer-destructuring": "off", - "no-restricted-globals": [2, "event"], - "prefer-promise-reject-errors": "off", - "import/prefer-default-export": "off", - "import/no-default-export": "off", - "import/no-unresolved": "off", - "import/no-cycle": "off", - "import/extensions": [ - "error", - "ignorePackages", - { - "ts": "never", - "js": "never" - } - ], - "no-restricted-syntax": ["error", "LabeledStatement", "WithStatement"], - "object-curly-newline": "off", - "default-case": "off", - "wc/no-self-class": "off", - "no-shadow": "off", - "@typescript-eslint/camelcase": "off", - "@typescript-eslint/ban-ts-comment": "off", - "@typescript-eslint/no-use-before-define": "off", - "@typescript-eslint/no-non-null-assertion": "off", - "@typescript-eslint/no-explicit-any": "off", - "@typescript-eslint/explicit-function-return-type": "off", - "@typescript-eslint/explicit-module-boundary-types": "off", - "@typescript-eslint/no-shadow": ["error"], - "@typescript-eslint/naming-convention": [ - "off", - { - "selector": "default", - "format": ["camelCase", "snake_case"], - "leadingUnderscore": "allow", - "trailingUnderscore": "allow" - }, - { - "selector": ["variable"], - "format": ["camelCase", "snake_case", "UPPER_CASE"], - "leadingUnderscore": "allow", - "trailingUnderscore": "allow" - }, - { - "selector": "typeLike", - "format": ["PascalCase"] - } - ], - "@typescript-eslint/no-unused-vars": "off", - "unused-imports/no-unused-vars": [ - "error", - { - "vars": "all", - "varsIgnorePattern": "^_", - "args": "after-used", - "argsIgnorePattern": "^_", - "ignoreRestSiblings": true - } - ], - "unused-imports/no-unused-imports": "error", - "lit/attribute-names": "warn", - "lit/attribute-value-entities": "off", - "lit/no-template-map": "off", - "lit/no-native-attributes": "warn", - "lit/no-this-assign-in-render": "warn", - "lit-a11y/click-events-have-key-events": ["off"], - "lit-a11y/no-autofocus": "off", - "lit-a11y/alt-text": "warn", - "lit-a11y/anchor-is-valid": "warn", - "lit-a11y/role-has-required-aria-attrs": "warn" - }, - "plugins": ["unused-imports"] -} diff --git a/build-scripts/.eslintrc.json b/build-scripts/.eslintrc.json deleted file mode 100644 index 3391c376db6f..000000000000 --- a/build-scripts/.eslintrc.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "extends": "../.eslintrc.json", - "rules": { - "no-console": "off", - "import/no-extraneous-dependencies": "off", - "import/extensions": "off", - "import/no-dynamic-require": "off", - "global-require": "off", - "@typescript-eslint/no-var-requires": "off", - "prefer-arrow-callback": "off" - } -} diff --git a/build-scripts/eslint.config.mjs b/build-scripts/eslint.config.mjs new file mode 100644 index 000000000000..3b703dc210de --- /dev/null +++ b/build-scripts/eslint.config.mjs @@ -0,0 +1,16 @@ +import rootConfig from "../eslint.config.mjs"; + +export default [ + ...rootConfig, + { + rules: { + "no-console": "off", + "import/no-extraneous-dependencies": "off", + "import/extensions": "off", + "import/no-dynamic-require": "off", + "global-require": "off", + "@typescript-eslint/no-var-requires": "off", + "prefer-arrow-callback": "off", + }, + }, +]; diff --git a/eslint.config.mjs b/eslint.config.mjs new file mode 100644 index 000000000000..f13760ea62a7 --- /dev/null +++ b/eslint.config.mjs @@ -0,0 +1,146 @@ +import unusedImports from "eslint-plugin-unused-imports"; +import globals from "globals"; +import tsParser from "@typescript-eslint/parser"; +import path from "node:path"; +import { fileURLToPath } from "node:url"; +import js from "@eslint/js"; +import { FlatCompat } from "@eslint/eslintrc"; + +const __filename = fileURLToPath(import.meta.url); +const __dirname = path.dirname(__filename); +const compat = new FlatCompat({ + baseDirectory: __dirname, + recommendedConfig: js.configs.recommended, + allConfig: js.configs.all +}); + +export default [...compat.extends( + "airbnb-base", + "airbnb-typescript/base", + "plugin:@typescript-eslint/recommended", + "plugin:wc/recommended", + "plugin:lit/all", + "plugin:lit-a11y/recommended", + "prettier", +), { + plugins: { + "unused-imports": unusedImports, + }, + + languageOptions: { + globals: { + ...globals.browser, + __DEV__: false, + __DEMO__: false, + __BUILD__: false, + __VERSION__: false, + __STATIC_PATH__: false, + __SUPERVISOR__: false, + Polymer: true, + }, + + parser: tsParser, + ecmaVersion: 2020, + sourceType: "module", + + parserOptions: { + ecmaFeatures: { + modules: true, + }, + + project: "./tsconfig.json", + }, + }, + + settings: { + "import/resolver": { + webpack: { + config: "./webpack.config.cjs", + }, + }, + }, + + rules: { + "class-methods-use-this": "off", + "new-cap": "off", + "prefer-template": "off", + "object-shorthand": "off", + "func-names": "off", + "no-underscore-dangle": "off", + strict: "off", + "no-plusplus": "off", + "no-bitwise": "error", + "comma-dangle": "off", + "vars-on-top": "off", + "no-continue": "off", + "no-param-reassign": "off", + "no-multi-assign": "off", + "no-console": "error", + radix: "off", + "no-alert": "off", + "no-nested-ternary": "off", + "prefer-destructuring": "off", + "no-restricted-globals": [2, "event"], + "prefer-promise-reject-errors": "off", + "import/prefer-default-export": "off", + "import/no-default-export": "off", + "import/no-unresolved": "off", + "import/no-cycle": "off", + + "import/extensions": ["error", "ignorePackages", { + ts: "never", + js: "never", + }], + + "no-restricted-syntax": ["error", "LabeledStatement", "WithStatement"], + "object-curly-newline": "off", + "default-case": "off", + "wc/no-self-class": "off", + "no-shadow": "off", + "@typescript-eslint/camelcase": "off", + "@typescript-eslint/ban-ts-comment": "off", + "@typescript-eslint/no-use-before-define": "off", + "@typescript-eslint/no-non-null-assertion": "off", + "@typescript-eslint/no-explicit-any": "off", + "@typescript-eslint/explicit-function-return-type": "off", + "@typescript-eslint/explicit-module-boundary-types": "off", + "@typescript-eslint/no-shadow": ["error"], + + "@typescript-eslint/naming-convention": ["off", { + selector: "default", + format: ["camelCase", "snake_case"], + leadingUnderscore: "allow", + trailingUnderscore: "allow", + }, { + selector: ["variable"], + format: ["camelCase", "snake_case", "UPPER_CASE"], + leadingUnderscore: "allow", + trailingUnderscore: "allow", + }, { + selector: "typeLike", + format: ["PascalCase"], + }], + + "@typescript-eslint/no-unused-vars": "off", + + "unused-imports/no-unused-vars": ["error", { + vars: "all", + varsIgnorePattern: "^_", + args: "after-used", + argsIgnorePattern: "^_", + ignoreRestSiblings: true, + }], + + "unused-imports/no-unused-imports": "error", + "lit/attribute-names": "warn", + "lit/attribute-value-entities": "off", + "lit/no-template-map": "off", + "lit/no-native-attributes": "warn", + "lit/no-this-assign-in-render": "warn", + "lit-a11y/click-events-have-key-events": ["off"], + "lit-a11y/no-autofocus": "off", + "lit-a11y/alt-text": "warn", + "lit-a11y/anchor-is-valid": "warn", + "lit-a11y/role-has-required-aria-attrs": "warn", + }, +}]; \ No newline at end of file diff --git a/gallery/.eslintrc.json b/gallery/.eslintrc.json deleted file mode 100644 index 59c30e3b6d13..000000000000 --- a/gallery/.eslintrc.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "extends": "../.eslintrc.json", - "rules": { - "no-console": 0 - } -} diff --git a/gallery/eslint.config.mjs b/gallery/eslint.config.mjs new file mode 100644 index 000000000000..95108521b0f9 --- /dev/null +++ b/gallery/eslint.config.mjs @@ -0,0 +1,10 @@ +import rootConfig from "../eslint.config.mjs"; + +export default [ + ...rootConfig, + { + rules: { + "no-console": "off", + }, + }, +]; diff --git a/package.json b/package.json index 1c116f8f6c31..10829868b4e9 100644 --- a/package.json +++ b/package.json @@ -8,8 +8,8 @@ "version": "1.0.0", "scripts": { "build": "script/build_frontend", - "lint:eslint": "eslint \"**/src/**/*.{js,ts,html}\" --cache --cache-strategy=content --cache-location=node_modules/.cache/eslint/.eslintcache --ignore-path=.gitignore", - "format:eslint": "eslint \"**/src/**/*.{js,ts,html}\" --cache --cache-strategy=content --cache-location=node_modules/.cache/eslint/.eslintcache --ignore-path=.gitignore --fix", + "lint:eslint": "eslint --flag unstable_config_lookup_from_file \"**/src/**/*.{js,ts,html}\" --cache --cache-strategy=content --cache-location=node_modules/.cache/eslint/.eslintcache --ignore-pattern=.gitignore", + "format:eslint": "eslint --flag unstable_config_lookup_from_file \"**/src/**/*.{js,ts,html}\" --cache --cache-strategy=content --cache-location=node_modules/.cache/eslint/.eslintcache --ignore-pattern=.gitignore --fix", "lint:prettier": "prettier . --cache --check", "format:prettier": "prettier . --cache --write", "lint:types": "tsc", @@ -195,7 +195,7 @@ "browserslist-useragent-regexp": "4.1.3", "chai": "5.1.1", "del": "7.1.0", - "eslint": "8.57.1", + "eslint": "eslint/eslint", "eslint-config-airbnb-base": "15.0.0", "eslint-config-airbnb-typescript": "18.0.0", "eslint-config-prettier": "9.1.0", @@ -255,7 +255,8 @@ "lit": "2.8.0", "clean-css": "5.3.3", "@lit/reactive-element": "1.6.3", - "@fullcalendar/daygrid": "6.1.15" + "@fullcalendar/daygrid": "6.1.15", + "globals": "^13.0.0" }, "packageManager": "yarn@4.5.0" } diff --git a/yarn.lock b/yarn.lock index bc6d5a16cd9e..a75538eae3ee 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1558,34 +1558,68 @@ __metadata: languageName: node linkType: hard -"@eslint-community/regexpp@npm:^4.10.0, @eslint-community/regexpp@npm:^4.6.1": +"@eslint-community/regexpp@npm:^4.10.0, @eslint-community/regexpp@npm:^4.11.0": version: 4.11.1 resolution: "@eslint-community/regexpp@npm:4.11.1" checksum: 10/934b6d3588c7f16b18d41efec4fdb89616c440b7e3256b8cb92cfd31ae12908600f2b986d6c1e61a84cbc10256b1dd3448cd1eec79904bd67ac365d0f1aba2e2 languageName: node linkType: hard -"@eslint/eslintrc@npm:^2.1.4": - version: 2.1.4 - resolution: "@eslint/eslintrc@npm:2.1.4" +"@eslint/config-array@npm:^0.18.0": + version: 0.18.0 + resolution: "@eslint/config-array@npm:0.18.0" + dependencies: + "@eslint/object-schema": "npm:^2.1.4" + debug: "npm:^4.3.1" + minimatch: "npm:^3.1.2" + checksum: 10/60ccad1eb4806710b085cd739568ec7afd289ee5af6ca0383f0876f9fe375559ef525f7b3f86bdb3f961493de952f2cf3ab4aa4a6ccaef0ae3cd688267cabcb3 + languageName: node + linkType: hard + +"@eslint/core@npm:^0.6.0": + version: 0.6.0 + resolution: "@eslint/core@npm:0.6.0" + checksum: 10/ec5cce168c8773fbd60c5a505563c6cf24398b3e1fa352929878d63129e0dd5b134d3232be2f2c49e8124a965d03359b38962aa0dcf7dfaf50746059d2a2f798 + languageName: node + linkType: hard + +"@eslint/eslintrc@npm:^3.1.0": + version: 3.1.0 + resolution: "@eslint/eslintrc@npm:3.1.0" dependencies: ajv: "npm:^6.12.4" debug: "npm:^4.3.2" - espree: "npm:^9.6.0" - globals: "npm:^13.19.0" + espree: "npm:^10.0.1" + globals: "npm:^14.0.0" ignore: "npm:^5.2.0" import-fresh: "npm:^3.2.1" js-yaml: "npm:^4.1.0" minimatch: "npm:^3.1.2" strip-json-comments: "npm:^3.1.1" - checksum: 10/7a3b14f4b40fc1a22624c3f84d9f467a3d9ea1ca6e9a372116cb92507e485260359465b58e25bcb6c9981b155416b98c9973ad9b796053fd7b3f776a6946bce8 + checksum: 10/02bf892d1397e1029209dea685e9f4f87baf643315df2a632b5f121ec7e8548a3b34f428a007234fa82772218fa8a3ac2d10328637b9ce63b7f8344035b74db3 + languageName: node + linkType: hard + +"@eslint/js@npm:9.11.1": + version: 9.11.1 + resolution: "@eslint/js@npm:9.11.1" + checksum: 10/77b9c744bdf24e2ca1f99f671139767d6c31cb10d732cf22a85ef28f1f95f2a621cf204f572fd9fee67da6193ff2597a5d236cef3b557b07624230b622612339 + languageName: node + linkType: hard + +"@eslint/object-schema@npm:^2.1.4": + version: 2.1.4 + resolution: "@eslint/object-schema@npm:2.1.4" + checksum: 10/221e8d9f281c605948cd6e030874aacce83fe097f8f9c1964787037bccf08e82b7aa9eff1850a30fffac43f1d76555727ec22a2af479d91e268e89d1e035131e languageName: node linkType: hard -"@eslint/js@npm:8.57.1": - version: 8.57.1 - resolution: "@eslint/js@npm:8.57.1" - checksum: 10/7562b21be10c2adbfa4aa5bb2eccec2cb9ac649a3569560742202c8d1cb6c931ce634937a2f0f551e078403a1c1285d6c2c0aa345dafc986149665cd69fe8b59 +"@eslint/plugin-kit@npm:^0.2.0": + version: 0.2.0 + resolution: "@eslint/plugin-kit@npm:0.2.0" + dependencies: + levn: "npm:^0.4.1" + checksum: 10/ebb363174397341dea47dc35fc206e24328083e4f0fa1c539687dbb7f94bef77e43faa12867d032e6eea5ac980ea8fbb6b1d844186e422d327c04088041b99f3 languageName: node linkType: hard @@ -1816,14 +1850,20 @@ __metadata: languageName: node linkType: hard -"@humanwhocodes/config-array@npm:^0.13.0": - version: 0.13.0 - resolution: "@humanwhocodes/config-array@npm:0.13.0" +"@humanfs/core@npm:^0.19.0": + version: 0.19.0 + resolution: "@humanfs/core@npm:0.19.0" + checksum: 10/9c4f96b9e934b7d2f69c5ee8b9414dcaf5c5a03225eb08f8ace3b80429c0fc796e11c4e2ef182172790e7b4560b1137ef984da4dc9662cdd5e3e92baceb02821 + languageName: node + linkType: hard + +"@humanfs/node@npm:^0.16.5": + version: 0.16.5 + resolution: "@humanfs/node@npm:0.16.5" dependencies: - "@humanwhocodes/object-schema": "npm:^2.0.3" - debug: "npm:^4.3.1" - minimatch: "npm:^3.0.5" - checksum: 10/524df31e61a85392a2433bf5d03164e03da26c03d009f27852e7dcfdafbc4a23f17f021dacf88e0a7a9fe04ca032017945d19b57a16e2676d9114c22a53a9d11 + "@humanfs/core": "npm:^0.19.0" + "@humanwhocodes/retry": "npm:^0.3.0" + checksum: 10/16e49b5f9d4a3cf8205af18f0909b8c6e00faa70a0e01bc606b413423ee20123e53028b6ca22c57725595341d62e148cd1908c297a761ee495087cc674f7b0a6 languageName: node linkType: hard @@ -1834,10 +1874,10 @@ __metadata: languageName: node linkType: hard -"@humanwhocodes/object-schema@npm:^2.0.3": - version: 2.0.3 - resolution: "@humanwhocodes/object-schema@npm:2.0.3" - checksum: 10/05bb99ed06c16408a45a833f03a732f59bf6184795d4efadd33238ff8699190a8c871ad1121241bb6501589a9598dc83bf25b99dcbcf41e155cdf36e35e937a3 +"@humanwhocodes/retry@npm:^0.3.0": + version: 0.3.0 + resolution: "@humanwhocodes/retry@npm:0.3.0" + checksum: 10/e574bab58680867414e225c9002e9a97eb396f85871c180fbb1a9bcdf9ded4b4de0b327f7d0c43b775873362b7c92956d4b322e8bc4b90be56077524341f04b2 languageName: node linkType: hard @@ -3248,7 +3288,7 @@ __metadata: languageName: node linkType: hard -"@nodelib/fs.walk@npm:^1.2.3, @nodelib/fs.walk@npm:^1.2.8": +"@nodelib/fs.walk@npm:^1.2.3": version: 1.2.8 resolution: "@nodelib/fs.walk@npm:1.2.8" dependencies: @@ -4083,7 +4123,7 @@ __metadata: languageName: node linkType: hard -"@types/estree@npm:*, @types/estree@npm:^1.0.0, @types/estree@npm:^1.0.5": +"@types/estree@npm:*, @types/estree@npm:^1.0.0, @types/estree@npm:^1.0.5, @types/estree@npm:^1.0.6": version: 1.0.6 resolution: "@types/estree@npm:1.0.6" checksum: 10/9d35d475095199c23e05b431bcdd1f6fec7380612aed068b14b2a08aa70494de8a9026765a5a91b1073f636fb0368f6d8973f518a31391d519e20c59388ed88d @@ -4205,7 +4245,7 @@ __metadata: languageName: node linkType: hard -"@types/json-schema@npm:^7.0.8, @types/json-schema@npm:^7.0.9": +"@types/json-schema@npm:^7.0.15, @types/json-schema@npm:^7.0.8, @types/json-schema@npm:^7.0.9": version: 7.0.15 resolution: "@types/json-schema@npm:7.0.15" checksum: 10/1a3c3e06236e4c4aab89499c428d585527ce50c24fe8259e8b3926d3df4cfbbbcf306cfc73ddfb66cbafc973116efd15967020b0f738f63e09e64c7d260519e7 @@ -4652,13 +4692,6 @@ __metadata: languageName: node linkType: hard -"@ungap/structured-clone@npm:^1.2.0": - version: 1.2.0 - resolution: "@ungap/structured-clone@npm:1.2.0" - checksum: 10/c6fe89a505e513a7592e1438280db1c075764793a2397877ff1351721fe8792a966a5359769e30242b3cd023f2efb9e63ca2ca88019d73b564488cc20e3eab12 - languageName: node - linkType: hard - "@vaadin/a11y-base@npm:~24.4.9": version: 24.4.9 resolution: "@vaadin/a11y-base@npm:24.4.9" @@ -5320,7 +5353,7 @@ __metadata: languageName: node linkType: hard -"acorn@npm:^8.5.0, acorn@npm:^8.7.1, acorn@npm:^8.8.2, acorn@npm:^8.9.0": +"acorn@npm:^8.12.0, acorn@npm:^8.5.0, acorn@npm:^8.7.1, acorn@npm:^8.8.2": version: 8.12.1 resolution: "acorn@npm:8.12.1" bin: @@ -7088,15 +7121,6 @@ __metadata: languageName: node linkType: hard -"doctrine@npm:^3.0.0": - version: 3.0.0 - resolution: "doctrine@npm:3.0.0" - dependencies: - esutils: "npm:^2.0.2" - checksum: 10/b4b28f1df5c563f7d876e7461254a4597b8cabe915abe94d7c5d1633fed263fcf9a85e8d3836591fc2d040108e822b0d32758e5ec1fe31c590dc7e08086e3e48 - languageName: node - linkType: hard - "dom-walk@npm:^0.1.0": version: 0.1.2 resolution: "dom-walk@npm:0.1.2" @@ -7646,83 +7670,93 @@ __metadata: languageName: node linkType: hard -"eslint-scope@npm:^7.2.2": - version: 7.2.2 - resolution: "eslint-scope@npm:7.2.2" +"eslint-scope@npm:^8.1.0": + version: 8.1.0 + resolution: "eslint-scope@npm:8.1.0" dependencies: esrecurse: "npm:^4.3.0" estraverse: "npm:^5.2.0" - checksum: 10/5c660fb905d5883ad018a6fea2b49f3cb5b1cbf2cd4bd08e98646e9864f9bc2c74c0839bed2d292e90a4a328833accc197c8f0baed89cbe8d605d6f918465491 + checksum: 10/4c34a12fbeb0677822a9e93e81f2027e39e6f27557c17bc1e5ff76debbd41e748c3673517561792bda9e276245f89fbfd9b0b24fcec3b33a04ee2196729b3489 languageName: node linkType: hard -"eslint-visitor-keys@npm:^3.3.0, eslint-visitor-keys@npm:^3.4.1, eslint-visitor-keys@npm:^3.4.3": +"eslint-visitor-keys@npm:^3.3.0, eslint-visitor-keys@npm:^3.4.3": version: 3.4.3 resolution: "eslint-visitor-keys@npm:3.4.3" checksum: 10/3f357c554a9ea794b094a09bd4187e5eacd1bc0d0653c3adeb87962c548e6a1ab8f982b86963ae1337f5d976004146536dcee5d0e2806665b193fbfbf1a9231b languageName: node linkType: hard -"eslint@npm:8.57.1": - version: 8.57.1 - resolution: "eslint@npm:8.57.1" +"eslint-visitor-keys@npm:^4.1.0": + version: 4.1.0 + resolution: "eslint-visitor-keys@npm:4.1.0" + checksum: 10/3fb5bd1b2f36db89d0ac57ddd66d36ccd3b1e3cddb2a55a0f9f6f1c85268cfcc1cc32e7eda4990e3423107a120dd254fb6cb52d6154cf81d344d8c3fa671f7c2 + languageName: node + linkType: hard + +eslint@eslint/eslint: + version: 9.11.1 + resolution: "eslint@https://github.com/eslint/eslint.git#commit=5a6a05321ca34480c780be8c2cb7946e4c299001" dependencies: "@eslint-community/eslint-utils": "npm:^4.2.0" - "@eslint-community/regexpp": "npm:^4.6.1" - "@eslint/eslintrc": "npm:^2.1.4" - "@eslint/js": "npm:8.57.1" - "@humanwhocodes/config-array": "npm:^0.13.0" + "@eslint-community/regexpp": "npm:^4.11.0" + "@eslint/config-array": "npm:^0.18.0" + "@eslint/core": "npm:^0.6.0" + "@eslint/eslintrc": "npm:^3.1.0" + "@eslint/js": "npm:9.11.1" + "@eslint/plugin-kit": "npm:^0.2.0" + "@humanfs/node": "npm:^0.16.5" "@humanwhocodes/module-importer": "npm:^1.0.1" - "@nodelib/fs.walk": "npm:^1.2.8" - "@ungap/structured-clone": "npm:^1.2.0" + "@humanwhocodes/retry": "npm:^0.3.0" + "@types/estree": "npm:^1.0.6" + "@types/json-schema": "npm:^7.0.15" ajv: "npm:^6.12.4" chalk: "npm:^4.0.0" cross-spawn: "npm:^7.0.2" debug: "npm:^4.3.2" - doctrine: "npm:^3.0.0" escape-string-regexp: "npm:^4.0.0" - eslint-scope: "npm:^7.2.2" - eslint-visitor-keys: "npm:^3.4.3" - espree: "npm:^9.6.1" - esquery: "npm:^1.4.2" + eslint-scope: "npm:^8.1.0" + eslint-visitor-keys: "npm:^4.1.0" + espree: "npm:^10.2.0" + esquery: "npm:^1.5.0" esutils: "npm:^2.0.2" fast-deep-equal: "npm:^3.1.3" - file-entry-cache: "npm:^6.0.1" + file-entry-cache: "npm:^8.0.0" find-up: "npm:^5.0.0" glob-parent: "npm:^6.0.2" - globals: "npm:^13.19.0" - graphemer: "npm:^1.4.0" ignore: "npm:^5.2.0" imurmurhash: "npm:^0.1.4" is-glob: "npm:^4.0.0" - is-path-inside: "npm:^3.0.3" - js-yaml: "npm:^4.1.0" json-stable-stringify-without-jsonify: "npm:^1.0.1" - levn: "npm:^0.4.1" lodash.merge: "npm:^4.6.2" minimatch: "npm:^3.1.2" natural-compare: "npm:^1.4.0" optionator: "npm:^0.9.3" strip-ansi: "npm:^6.0.1" text-table: "npm:^0.2.0" + peerDependencies: + jiti: "*" + peerDependenciesMeta: + jiti: + optional: true bin: - eslint: bin/eslint.js - checksum: 10/5504fa24879afdd9f9929b2fbfc2ee9b9441a3d464efd9790fbda5f05738858530182029f13323add68d19fec749d3ab4a70320ded091ca4432b1e9cc4ed104c + eslint: ./bin/eslint.js + checksum: 10/fd3a3b13bd97b9ff18d9dea4b7f04bc7b8d5cb62ec2cca65a4feba3b9ba4ec03d56b78b28a027025f5c52f2ef589053982391eab7d48524bea3e53cc92a90d0c languageName: node linkType: hard -"espree@npm:^9.6.0, espree@npm:^9.6.1": - version: 9.6.1 - resolution: "espree@npm:9.6.1" +"espree@npm:^10.0.1, espree@npm:^10.2.0": + version: 10.2.0 + resolution: "espree@npm:10.2.0" dependencies: - acorn: "npm:^8.9.0" + acorn: "npm:^8.12.0" acorn-jsx: "npm:^5.3.2" - eslint-visitor-keys: "npm:^3.4.1" - checksum: 10/255ab260f0d711a54096bdeda93adff0eadf02a6f9b92f02b323e83a2b7fc258797919437ad331efec3930475feb0142c5ecaaf3cdab4befebd336d47d3f3134 + eslint-visitor-keys: "npm:^4.1.0" + checksum: 10/365076a963ca84244c1e2d36e4f812362d21cfa7e7df10d67f7b82b759467796df81184721d153c4e235d9ef5eb5b4d044167dd66be3be00f53a21a515b1bfb1 languageName: node linkType: hard -"esquery@npm:^1.4.2": +"esquery@npm:^1.5.0": version: 1.6.0 resolution: "esquery@npm:1.6.0" dependencies: @@ -8027,12 +8061,12 @@ __metadata: languageName: node linkType: hard -"file-entry-cache@npm:^6.0.1": - version: 6.0.1 - resolution: "file-entry-cache@npm:6.0.1" +"file-entry-cache@npm:^8.0.0": + version: 8.0.0 + resolution: "file-entry-cache@npm:8.0.0" dependencies: - flat-cache: "npm:^3.0.4" - checksum: 10/099bb9d4ab332cb93c48b14807a6918a1da87c45dce91d4b61fd40e6505d56d0697da060cb901c729c90487067d93c9243f5da3dc9c41f0358483bfdebca736b + flat-cache: "npm:^4.0.0" + checksum: 10/afe55c4de4e0d226a23c1eae62a7219aafb390859122608a89fa4df6addf55c7fd3f1a2da6f5b41e7cdff496e4cf28bbd215d53eab5c817afa96d2b40c81bfb0 languageName: node linkType: hard @@ -8168,14 +8202,13 @@ __metadata: languageName: node linkType: hard -"flat-cache@npm:^3.0.4": - version: 3.2.0 - resolution: "flat-cache@npm:3.2.0" +"flat-cache@npm:^4.0.0": + version: 4.0.1 + resolution: "flat-cache@npm:4.0.1" dependencies: flatted: "npm:^3.2.9" - keyv: "npm:^4.5.3" - rimraf: "npm:^3.0.2" - checksum: 10/02381c6ece5e9fa5b826c9bbea481d7fd77645d96e4b0b1395238124d581d10e56f17f723d897b6d133970f7a57f0fab9148cbbb67237a0a0ffe794ba60c0c70 + keyv: "npm:^4.5.4" + checksum: 10/58ce851d9045fffc7871ce2bd718bc485ad7e777bf748c054904b87c351ff1080c2c11da00788d78738bfb51b71e4d5ea12d13b98eb36e3358851ffe495b62dc languageName: node linkType: hard @@ -8605,14 +8638,7 @@ __metadata: languageName: node linkType: hard -"globals@npm:^11.1.0": - version: 11.12.0 - resolution: "globals@npm:11.12.0" - checksum: 10/9f054fa38ff8de8fa356502eb9d2dae0c928217b8b5c8de1f09f5c9b6c8a96d8b9bd3afc49acbcd384a98a81fea713c859e1b09e214c60509517bb8fc2bc13c2 - languageName: node - linkType: hard - -"globals@npm:^13.19.0": +"globals@npm:^13.0.0": version: 13.24.0 resolution: "globals@npm:13.24.0" dependencies: @@ -9011,7 +9037,7 @@ __metadata: del: "npm:7.1.0" dialog-polyfill: "npm:0.5.6" element-internals-polyfill: "npm:1.3.11" - eslint: "npm:8.57.1" + eslint: eslint/eslint eslint-config-airbnb-base: "npm:15.0.0" eslint-config-airbnb-typescript: "npm:18.0.0" eslint-config-prettier: "npm:9.1.0" @@ -9786,13 +9812,6 @@ __metadata: languageName: node linkType: hard -"is-path-inside@npm:^3.0.3": - version: 3.0.3 - resolution: "is-path-inside@npm:3.0.3" - checksum: 10/abd50f06186a052b349c15e55b182326f1936c89a78bf6c8f2b707412517c097ce04bc49a0ca221787bc44e1049f51f09a2ffb63d22899051988d3a618ba13e9 - languageName: node - linkType: hard - "is-path-inside@npm:^4.0.0": version: 4.0.0 resolution: "is-path-inside@npm:4.0.0" @@ -10259,7 +10278,7 @@ __metadata: languageName: node linkType: hard -"keyv@npm:^4.5.3": +"keyv@npm:^4.5.4": version: 4.5.4 resolution: "keyv@npm:4.5.4" dependencies: @@ -10990,7 +11009,7 @@ __metadata: languageName: node linkType: hard -"minimatch@npm:3.1.2, minimatch@npm:^3.0.5, minimatch@npm:^3.1.1, minimatch@npm:^3.1.2": +"minimatch@npm:3.1.2, minimatch@npm:^3.1.1, minimatch@npm:^3.1.2": version: 3.1.2 resolution: "minimatch@npm:3.1.2" dependencies: From 4554a42ed3c0925b5b06eae10eb07573879c7a78 Mon Sep 17 00:00:00 2001 From: Simon Lamon <32477463+silamon@users.noreply.github.com> Date: Thu, 3 Oct 2024 17:36:35 +0000 Subject: [PATCH 2/7] Plugin --- package.json | 2 +- yarn.lock | 23 ++++++++++++----------- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/package.json b/package.json index 10829868b4e9..71849a0bc19a 100644 --- a/package.json +++ b/package.json @@ -200,7 +200,7 @@ "eslint-config-airbnb-typescript": "18.0.0", "eslint-config-prettier": "9.1.0", "eslint-import-resolver-webpack": "0.13.9", - "eslint-plugin-import": "2.30.0", + "eslint-plugin-import": "2.31.0", "eslint-plugin-lit": "1.15.0", "eslint-plugin-lit-a11y": "4.1.4", "eslint-plugin-unused-imports": "4.1.4", diff --git a/yarn.lock b/yarn.lock index a75538eae3ee..f99b58ae0173 100644 --- a/yarn.lock +++ b/yarn.lock @@ -7554,21 +7554,21 @@ __metadata: languageName: node linkType: hard -"eslint-module-utils@npm:^2.9.0": - version: 2.11.0 - resolution: "eslint-module-utils@npm:2.11.0" +"eslint-module-utils@npm:^2.12.0": + version: 2.12.0 + resolution: "eslint-module-utils@npm:2.12.0" dependencies: debug: "npm:^3.2.7" peerDependenciesMeta: eslint: optional: true - checksum: 10/1ba42cf48c5f9ec3b76dfa42c16f1c24c10508313689425c05ccb1d0eaa34bdc5c5b9c0c033cd402e9c429666bd3eb8c6d0c66565b0c00949fae743ad3643c95 + checksum: 10/dd27791147eca17366afcb83f47d6825b6ce164abb256681e5de4ec1d7e87d8605641eb869298a0dbc70665e2446dbcc2f40d3e1631a9475dd64dd23d4ca5dee languageName: node linkType: hard -"eslint-plugin-import@npm:2.30.0": - version: 2.30.0 - resolution: "eslint-plugin-import@npm:2.30.0" +"eslint-plugin-import@npm:2.31.0": + version: 2.31.0 + resolution: "eslint-plugin-import@npm:2.31.0" dependencies: "@rtsao/scc": "npm:^1.1.0" array-includes: "npm:^3.1.8" @@ -7578,7 +7578,7 @@ __metadata: debug: "npm:^3.2.7" doctrine: "npm:^2.1.0" eslint-import-resolver-node: "npm:^0.3.9" - eslint-module-utils: "npm:^2.9.0" + eslint-module-utils: "npm:^2.12.0" hasown: "npm:^2.0.2" is-core-module: "npm:^2.15.1" is-glob: "npm:^4.0.3" @@ -7587,10 +7587,11 @@ __metadata: object.groupby: "npm:^1.0.3" object.values: "npm:^1.2.0" semver: "npm:^6.3.1" + string.prototype.trimend: "npm:^1.0.8" tsconfig-paths: "npm:^3.15.0" peerDependencies: - eslint: ^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 - checksum: 10/a5f85dfe76e27286c28a01d137769726ce3f758bcc03aa6b6f9e18700a40a08f57239f82e07efcab763c4b03a02d425edcc29fbecf40aad0124286978c6bc63c + eslint: ^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 || ^9 + checksum: 10/6b76bd009ac2db0615d9019699d18e2a51a86cb8c1d0855a35fb1b418be23b40239e6debdc6e8c92c59f1468ed0ea8d7b85c817117a113d5cc225be8a02ad31c languageName: node linkType: hard @@ -9042,7 +9043,7 @@ eslint@eslint/eslint: eslint-config-airbnb-typescript: "npm:18.0.0" eslint-config-prettier: "npm:9.1.0" eslint-import-resolver-webpack: "npm:0.13.9" - eslint-plugin-import: "npm:2.30.0" + eslint-plugin-import: "npm:2.31.0" eslint-plugin-lit: "npm:1.15.0" eslint-plugin-lit-a11y: "npm:4.1.4" eslint-plugin-unused-imports: "npm:4.1.4" From 26cf1995a041c3a22797bfa63bdb59cc60eed602 Mon Sep 17 00:00:00 2001 From: Simon Lamon <32477463+silamon@users.noreply.github.com> Date: Thu, 3 Oct 2024 18:08:24 +0000 Subject: [PATCH 3/7] prettier --- eslint.config.mjs | 227 ++++++++++++++++++++++++---------------------- 1 file changed, 121 insertions(+), 106 deletions(-) diff --git a/eslint.config.mjs b/eslint.config.mjs index f13760ea62a7..d39a4651d445 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -9,138 +9,153 @@ import { FlatCompat } from "@eslint/eslintrc"; const __filename = fileURLToPath(import.meta.url); const __dirname = path.dirname(__filename); const compat = new FlatCompat({ - baseDirectory: __dirname, - recommendedConfig: js.configs.recommended, - allConfig: js.configs.all + baseDirectory: __dirname, + recommendedConfig: js.configs.recommended, + allConfig: js.configs.all, }); -export default [...compat.extends( +export default [ + ...compat.extends( "airbnb-base", "airbnb-typescript/base", "plugin:@typescript-eslint/recommended", "plugin:wc/recommended", "plugin:lit/all", "plugin:lit-a11y/recommended", - "prettier", -), { + "prettier" + ), + { plugins: { - "unused-imports": unusedImports, + "unused-imports": unusedImports, }, languageOptions: { - globals: { - ...globals.browser, - __DEV__: false, - __DEMO__: false, - __BUILD__: false, - __VERSION__: false, - __STATIC_PATH__: false, - __SUPERVISOR__: false, - Polymer: true, - }, - - parser: tsParser, - ecmaVersion: 2020, - sourceType: "module", + globals: { + ...globals.browser, + __DEV__: false, + __DEMO__: false, + __BUILD__: false, + __VERSION__: false, + __STATIC_PATH__: false, + __SUPERVISOR__: false, + Polymer: true, + }, - parserOptions: { - ecmaFeatures: { - modules: true, - }, + parser: tsParser, + ecmaVersion: 2020, + sourceType: "module", - project: "./tsconfig.json", + parserOptions: { + ecmaFeatures: { + modules: true, }, + + project: "./tsconfig.json", + }, }, settings: { - "import/resolver": { - webpack: { - config: "./webpack.config.cjs", - }, + "import/resolver": { + webpack: { + config: "./webpack.config.cjs", }, + }, }, rules: { - "class-methods-use-this": "off", - "new-cap": "off", - "prefer-template": "off", - "object-shorthand": "off", - "func-names": "off", - "no-underscore-dangle": "off", - strict: "off", - "no-plusplus": "off", - "no-bitwise": "error", - "comma-dangle": "off", - "vars-on-top": "off", - "no-continue": "off", - "no-param-reassign": "off", - "no-multi-assign": "off", - "no-console": "error", - radix: "off", - "no-alert": "off", - "no-nested-ternary": "off", - "prefer-destructuring": "off", - "no-restricted-globals": [2, "event"], - "prefer-promise-reject-errors": "off", - "import/prefer-default-export": "off", - "import/no-default-export": "off", - "import/no-unresolved": "off", - "import/no-cycle": "off", + "class-methods-use-this": "off", + "new-cap": "off", + "prefer-template": "off", + "object-shorthand": "off", + "func-names": "off", + "no-underscore-dangle": "off", + strict: "off", + "no-plusplus": "off", + "no-bitwise": "error", + "comma-dangle": "off", + "vars-on-top": "off", + "no-continue": "off", + "no-param-reassign": "off", + "no-multi-assign": "off", + "no-console": "error", + radix: "off", + "no-alert": "off", + "no-nested-ternary": "off", + "prefer-destructuring": "off", + "no-restricted-globals": [2, "event"], + "prefer-promise-reject-errors": "off", + "import/prefer-default-export": "off", + "import/no-default-export": "off", + "import/no-unresolved": "off", + "import/no-cycle": "off", - "import/extensions": ["error", "ignorePackages", { - ts: "never", - js: "never", - }], + "import/extensions": [ + "error", + "ignorePackages", + { + ts: "never", + js: "never", + }, + ], - "no-restricted-syntax": ["error", "LabeledStatement", "WithStatement"], - "object-curly-newline": "off", - "default-case": "off", - "wc/no-self-class": "off", - "no-shadow": "off", - "@typescript-eslint/camelcase": "off", - "@typescript-eslint/ban-ts-comment": "off", - "@typescript-eslint/no-use-before-define": "off", - "@typescript-eslint/no-non-null-assertion": "off", - "@typescript-eslint/no-explicit-any": "off", - "@typescript-eslint/explicit-function-return-type": "off", - "@typescript-eslint/explicit-module-boundary-types": "off", - "@typescript-eslint/no-shadow": ["error"], + "no-restricted-syntax": ["error", "LabeledStatement", "WithStatement"], + "object-curly-newline": "off", + "default-case": "off", + "wc/no-self-class": "off", + "no-shadow": "off", + "@typescript-eslint/camelcase": "off", + "@typescript-eslint/ban-ts-comment": "off", + "@typescript-eslint/no-use-before-define": "off", + "@typescript-eslint/no-non-null-assertion": "off", + "@typescript-eslint/no-explicit-any": "off", + "@typescript-eslint/explicit-function-return-type": "off", + "@typescript-eslint/explicit-module-boundary-types": "off", + "@typescript-eslint/no-shadow": ["error"], - "@typescript-eslint/naming-convention": ["off", { - selector: "default", - format: ["camelCase", "snake_case"], - leadingUnderscore: "allow", - trailingUnderscore: "allow", - }, { - selector: ["variable"], - format: ["camelCase", "snake_case", "UPPER_CASE"], - leadingUnderscore: "allow", - trailingUnderscore: "allow", - }, { - selector: "typeLike", - format: ["PascalCase"], - }], + "@typescript-eslint/naming-convention": [ + "off", + { + selector: "default", + format: ["camelCase", "snake_case"], + leadingUnderscore: "allow", + trailingUnderscore: "allow", + }, + { + selector: ["variable"], + format: ["camelCase", "snake_case", "UPPER_CASE"], + leadingUnderscore: "allow", + trailingUnderscore: "allow", + }, + { + selector: "typeLike", + format: ["PascalCase"], + }, + ], - "@typescript-eslint/no-unused-vars": "off", + "@typescript-eslint/no-unused-vars": "off", - "unused-imports/no-unused-vars": ["error", { - vars: "all", - varsIgnorePattern: "^_", - args: "after-used", - argsIgnorePattern: "^_", - ignoreRestSiblings: true, - }], + "unused-imports/no-unused-vars": [ + "error", + { + vars: "all", + varsIgnorePattern: "^_", + args: "after-used", + argsIgnorePattern: "^_", + ignoreRestSiblings: true, + }, + ], - "unused-imports/no-unused-imports": "error", - "lit/attribute-names": "warn", - "lit/attribute-value-entities": "off", - "lit/no-template-map": "off", - "lit/no-native-attributes": "warn", - "lit/no-this-assign-in-render": "warn", - "lit-a11y/click-events-have-key-events": ["off"], - "lit-a11y/no-autofocus": "off", - "lit-a11y/alt-text": "warn", - "lit-a11y/anchor-is-valid": "warn", - "lit-a11y/role-has-required-aria-attrs": "warn", + "unused-imports/no-unused-imports": "error", + "lit/attribute-names": "warn", + "lit/attribute-value-entities": "off", + "lit/no-template-map": "off", + "lit/no-native-attributes": "warn", + "lit/no-this-assign-in-render": "warn", + "lit-a11y/click-events-have-key-events": ["off"], + "lit-a11y/no-autofocus": "off", + "lit-a11y/alt-text": "warn", + "lit-a11y/anchor-is-valid": "warn", + "lit-a11y/role-has-required-aria-attrs": "warn", }, -}]; \ No newline at end of file + }, +]; From a312dcd320c69205f0547e84785cfdc5e1b0fd44 Mon Sep 17 00:00:00 2001 From: Simon Lamon <32477463+silamon@users.noreply.github.com> Date: Sat, 5 Oct 2024 15:11:29 +0000 Subject: [PATCH 4/7] Set eslint to latest version (non dev) --- package.json | 2 +- yarn.lock | 33 ++++++++++++++++----------------- 2 files changed, 17 insertions(+), 18 deletions(-) diff --git a/package.json b/package.json index a3521c09870d..f4efb7b545e2 100644 --- a/package.json +++ b/package.json @@ -196,7 +196,7 @@ "browserslist-useragent-regexp": "4.1.3", "chai": "5.1.1", "del": "7.1.0", - "eslint": "eslint/eslint", + "eslint": "9.12.0", "eslint-config-airbnb-base": "15.0.0", "eslint-config-airbnb-typescript": "18.0.0", "eslint-config-prettier": "9.1.0", diff --git a/yarn.lock b/yarn.lock index ed643dae7a7f..0c75a6549ff4 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1600,10 +1600,10 @@ __metadata: languageName: node linkType: hard -"@eslint/js@npm:9.11.1": - version: 9.11.1 - resolution: "@eslint/js@npm:9.11.1" - checksum: 10/77b9c744bdf24e2ca1f99f671139767d6c31cb10d732cf22a85ef28f1f95f2a621cf204f572fd9fee67da6193ff2597a5d236cef3b557b07624230b622612339 +"@eslint/js@npm:9.12.0": + version: 9.12.0 + resolution: "@eslint/js@npm:9.12.0" + checksum: 10/c4ec9f7ff664f778324002bccdfd63e4a563018e4d7efc838d8149898f9df8649fbc51a379c3d7deea40da4fba9e8e62f39f2df3ff2b9616e2241bbfc10456b0 languageName: node linkType: hard @@ -1874,10 +1874,10 @@ __metadata: languageName: node linkType: hard -"@humanwhocodes/retry@npm:^0.3.0": - version: 0.3.0 - resolution: "@humanwhocodes/retry@npm:0.3.0" - checksum: 10/e574bab58680867414e225c9002e9a97eb396f85871c180fbb1a9bcdf9ded4b4de0b327f7d0c43b775873362b7c92956d4b322e8bc4b90be56077524341f04b2 +"@humanwhocodes/retry@npm:^0.3.0, @humanwhocodes/retry@npm:^0.3.1": + version: 0.3.1 + resolution: "@humanwhocodes/retry@npm:0.3.1" + checksum: 10/eb457f699529de7f07649679ec9e0353055eebe443c2efe71c6dd950258892475a038e13c6a8c5e13ed1fb538cdd0a8794faa96b24b6ffc4c87fb1fc9f70ad7f languageName: node linkType: hard @@ -7705,20 +7705,20 @@ __metadata: languageName: node linkType: hard -eslint@eslint/eslint: - version: 9.11.1 - resolution: "eslint@https://github.com/eslint/eslint.git#commit=5a6a05321ca34480c780be8c2cb7946e4c299001" +"eslint@npm:9.12.0": + version: 9.12.0 + resolution: "eslint@npm:9.12.0" dependencies: "@eslint-community/eslint-utils": "npm:^4.2.0" "@eslint-community/regexpp": "npm:^4.11.0" "@eslint/config-array": "npm:^0.18.0" "@eslint/core": "npm:^0.6.0" "@eslint/eslintrc": "npm:^3.1.0" - "@eslint/js": "npm:9.11.1" + "@eslint/js": "npm:9.12.0" "@eslint/plugin-kit": "npm:^0.2.0" "@humanfs/node": "npm:^0.16.5" "@humanwhocodes/module-importer": "npm:^1.0.1" - "@humanwhocodes/retry": "npm:^0.3.0" + "@humanwhocodes/retry": "npm:^0.3.1" "@types/estree": "npm:^1.0.6" "@types/json-schema": "npm:^7.0.15" ajv: "npm:^6.12.4" @@ -7743,7 +7743,6 @@ eslint@eslint/eslint: minimatch: "npm:^3.1.2" natural-compare: "npm:^1.4.0" optionator: "npm:^0.9.3" - strip-ansi: "npm:^6.0.1" text-table: "npm:^0.2.0" peerDependencies: jiti: "*" @@ -7751,8 +7750,8 @@ eslint@eslint/eslint: jiti: optional: true bin: - eslint: ./bin/eslint.js - checksum: 10/fd3a3b13bd97b9ff18d9dea4b7f04bc7b8d5cb62ec2cca65a4feba3b9ba4ec03d56b78b28a027025f5c52f2ef589053982391eab7d48524bea3e53cc92a90d0c + eslint: bin/eslint.js + checksum: 10/c3f10d1ca3798bf1d0f71e43846e254d4bf0ea9ffbb0e61f9686a98e412aa762a454c5e5ef4e74fd71956b1500c04817c9f08dbf7a0cec47317160e28f585e4f languageName: node linkType: hard @@ -9049,7 +9048,7 @@ eslint@eslint/eslint: del: "npm:7.1.0" dialog-polyfill: "npm:0.5.6" element-internals-polyfill: "npm:1.3.11" - eslint: eslint/eslint + eslint: "npm:9.12.0" eslint-config-airbnb-base: "npm:15.0.0" eslint-config-airbnb-typescript: "npm:18.0.0" eslint-config-prettier: "npm:9.1.0" From bf7baf193bac5425989968d3fd116bed61077f15 Mon Sep 17 00:00:00 2001 From: Simon Lamon <32477463+silamon@users.noreply.github.com> Date: Mon, 21 Oct 2024 18:34:56 +0000 Subject: [PATCH 5/7] yarn dedupe --- yarn.lock | 44 ++++---------------------------------------- 1 file changed, 4 insertions(+), 40 deletions(-) diff --git a/yarn.lock b/yarn.lock index 41324f722a72..495c0817f09d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1237,18 +1237,7 @@ __metadata: languageName: node linkType: hard -"@babel/types@npm:^7.25.7, @babel/types@npm:^7.4.4": - version: 7.25.7 - resolution: "@babel/types@npm:7.25.7" - dependencies: - "@babel/helper-string-parser": "npm:^7.25.7" - "@babel/helper-validator-identifier": "npm:^7.25.7" - to-fast-properties: "npm:^2.0.0" - checksum: 10/4504e16a95b6a67d50cfaa389bcbc0621019084cff73784ad4797f82d1bb76c870cb0abb6d9881d5776eb06b4607419a2b1205a08c3e87b152d74bd0884b822a - languageName: node - linkType: hard - -"@babel/types@npm:^7.25.8": +"@babel/types@npm:^7.25.7, @babel/types@npm:^7.25.8, @babel/types@npm:^7.4.4": version: 7.25.8 resolution: "@babel/types@npm:7.25.8" dependencies: @@ -3314,7 +3303,7 @@ __metadata: languageName: node linkType: hard -"@octokit/types@npm:^13.0.0, @octokit/types@npm:^13.1.0": +"@octokit/types@npm:^13.0.0, @octokit/types@npm:^13.1.0, @octokit/types@npm:^13.5.0": version: 13.6.1 resolution: "@octokit/types@npm:13.6.1" dependencies: @@ -3323,15 +3312,6 @@ __metadata: languageName: node linkType: hard -"@octokit/types@npm:^13.5.0": - version: 13.5.0 - resolution: "@octokit/types@npm:13.5.0" - dependencies: - "@octokit/openapi-types": "npm:^22.2.0" - checksum: 10/d2aeebc1d8684c4e950f054a52b484e898b72d9f5f8433bcf010161716eea20d1132820d922212f19557a8f147354f2674d1a27b22941308b7c298bdd2674ffa - languageName: node - linkType: hard - "@open-wc/dedupe-mixin@npm:^1.3.0": version: 1.4.0 resolution: "@open-wc/dedupe-mixin@npm:1.4.0" @@ -5245,16 +5225,7 @@ __metadata: languageName: node linkType: hard -"acorn@npm:^8.12.0": - version: 8.12.1 - resolution: "acorn@npm:8.12.1" - bin: - acorn: bin/acorn - checksum: 10/d08c2d122bba32d0861e0aa840b2ee25946c286d5dc5990abca991baf8cdbfbe199b05aacb221b979411a2fea36f83e26b5ac4f6b4e0ce49038c62316c1848f0 - languageName: node - linkType: hard - -"acorn@npm:^8.5.0, acorn@npm:^8.7.1, acorn@npm:^8.8.2": +"acorn@npm:^8.12.0, acorn@npm:^8.5.0, acorn@npm:^8.7.1, acorn@npm:^8.8.2": version: 8.13.0 resolution: "acorn@npm:8.13.0" bin: @@ -11835,20 +11806,13 @@ __metadata: languageName: node linkType: hard -"picocolors@npm:^1.0.0, picocolors@npm:^1.1.0": +"picocolors@npm:^1.0.0, picocolors@npm:^1.0.1, picocolors@npm:^1.1.0": version: 1.1.1 resolution: "picocolors@npm:1.1.1" checksum: 10/e1cf46bf84886c79055fdfa9dcb3e4711ad259949e3565154b004b260cd356c5d54b31a1437ce9782624bf766272fe6b0154f5f0c744fb7af5d454d2b60db045 languageName: node linkType: hard -"picocolors@npm:^1.0.1": - version: 1.1.0 - resolution: "picocolors@npm:1.1.0" - checksum: 10/a2ad60d94d185c30f2a140b19c512547713fb89b920d32cc6cf658fa786d63a37ba7b8451872c3d9fc34883971fb6e5878e07a20b60506e0bb2554dce9169ccb - languageName: node - linkType: hard - "picomatch@npm:^2.0.4, picomatch@npm:^2.2.1, picomatch@npm:^2.2.2, picomatch@npm:^2.3.1": version: 2.3.1 resolution: "picomatch@npm:2.3.1" From 4c877d00883e4a414a61d26561a35490912d6a08 Mon Sep 17 00:00:00 2001 From: Simon Lamon <32477463+silamon@users.noreply.github.com> Date: Wed, 30 Oct 2024 12:37:15 +0000 Subject: [PATCH 6/7] push changes from eslint type pr --- eslint.config.mjs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/eslint.config.mjs b/eslint.config.mjs index d39a4651d445..470fd23bcc54 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -156,6 +156,8 @@ export default [ "lit-a11y/alt-text": "warn", "lit-a11y/anchor-is-valid": "warn", "lit-a11y/role-has-required-aria-attrs": "warn", + "@typescript-eslint/consistent-type-imports": "error", + "@typescript-eslint/no-import-type-side-effects": "error", }, }, ]; From e7633237c98ec90c2a6efa955a5b6c4a43580723 Mon Sep 17 00:00:00 2001 From: Simon Lamon <32477463+silamon@users.noreply.github.com> Date: Wed, 6 Nov 2024 08:38:06 +0000 Subject: [PATCH 7/7] dedupe --- yarn.lock | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/yarn.lock b/yarn.lock index e941e8ba878c..aec9385e78ff 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5251,16 +5251,7 @@ __metadata: languageName: node linkType: hard -"acorn@npm:^8.12.0": - version: 8.13.0 - resolution: "acorn@npm:8.13.0" - bin: - acorn: bin/acorn - checksum: 10/33e3a03114b02b3bc5009463b3d9549b31a90ee38ebccd5e66515830a02acf62a90edcc12abfb6c9fb3837b6c17a3ec9b72b3bf52ac31d8ad8248a4af871e0f5 - languageName: node - linkType: hard - -"acorn@npm:^8.14.0, acorn@npm:^8.5.0, acorn@npm:^8.8.2": +"acorn@npm:^8.12.0, acorn@npm:^8.14.0, acorn@npm:^8.5.0, acorn@npm:^8.8.2": version: 8.14.0 resolution: "acorn@npm:8.14.0" bin: