diff --git a/eslint.config.mjs b/eslint.config.mjs index 7101067230b..1abde3ca428 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -48,6 +48,10 @@ export default [ }, rules: { ...reactHooks.configs.recommended.rules, + '@typescript-eslint/no-wrapper-object-types': 'off', + '@typescript-eslint/no-empty-object-type': 'off', + '@typescript-eslint/no-unsafe-function-type': 'off', + '@typescript-eslint/no-unused-expressions': ['error', { allowShortCircuit: true, allowTernary: true }], '@typescript-eslint/ban-ts-comment': 'off', '@typescript-eslint/adjacent-overload-signatures': 'error', '@typescript-eslint/array-type': 'error', @@ -67,11 +71,12 @@ export default [ '@typescript-eslint/no-unused-vars': [ 'error', { - argsIgnorePattern: '^_' + argsIgnorePattern: '^_', + caughtErrors: 'none' } ], '@typescript-eslint/no-use-before-define': 'off', - '@typescript-eslint/no-var-requires': 'off', + '@typescript-eslint/no-require-imports': 'off', '@typescript-eslint/prefer-for-of': 'error', '@typescript-eslint/prefer-function-type': 'error', '@typescript-eslint/prefer-namespace-keyword': 'error', diff --git a/package.json b/package.json index 23e936a9f0a..3950968f76d 100644 --- a/package.json +++ b/package.json @@ -77,7 +77,7 @@ "ts-node": "^10.9.2", "ts-patch": "^3.3.0", "typescript": "^5.4.5", - "typescript-eslint": "^7.18.0" + "typescript-eslint": "^8.22.0" }, "scripts": { "build": "yarn clean && yarn build:generate && yarn build:esm && yarn build:cjs && yarn build:subpaths && yarn build:single:packages", diff --git a/yarn.lock b/yarn.lock index efa60519802..d2c520f834f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3870,7 +3870,7 @@ __metadata: ts-node: "npm:^10.9.2" ts-patch: "npm:^3.3.0" typescript: "npm:^5.4.5" - typescript-eslint: "npm:^7.18.0" + typescript-eslint: "npm:^8.22.0" languageName: unknown linkType: soft @@ -5310,54 +5310,40 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/eslint-plugin@npm:7.18.0": - version: 7.18.0 - resolution: "@typescript-eslint/eslint-plugin@npm:7.18.0" +"@typescript-eslint/eslint-plugin@npm:8.26.1": + version: 8.26.1 + resolution: "@typescript-eslint/eslint-plugin@npm:8.26.1" dependencies: "@eslint-community/regexpp": "npm:^4.10.0" - "@typescript-eslint/scope-manager": "npm:7.18.0" - "@typescript-eslint/type-utils": "npm:7.18.0" - "@typescript-eslint/utils": "npm:7.18.0" - "@typescript-eslint/visitor-keys": "npm:7.18.0" + "@typescript-eslint/scope-manager": "npm:8.26.1" + "@typescript-eslint/type-utils": "npm:8.26.1" + "@typescript-eslint/utils": "npm:8.26.1" + "@typescript-eslint/visitor-keys": "npm:8.26.1" graphemer: "npm:^1.4.0" ignore: "npm:^5.3.1" natural-compare: "npm:^1.4.0" - ts-api-utils: "npm:^1.3.0" + ts-api-utils: "npm:^2.0.1" peerDependencies: - "@typescript-eslint/parser": ^7.0.0 - eslint: ^8.56.0 - peerDependenciesMeta: - typescript: - optional: true - checksum: 10c0/2b37948fa1b0dab77138909dabef242a4d49ab93e4019d4ef930626f0a7d96b03e696cd027fa0087881c20e73be7be77c942606b4a76fa599e6b37f6985304c3 + "@typescript-eslint/parser": ^8.0.0 || ^8.0.0-alpha.0 + eslint: ^8.57.0 || ^9.0.0 + typescript: ">=4.8.4 <5.9.0" + checksum: 10c0/412f41aafd503a1faea91edd03a68717ca8a49ed6683700b8386115c67b86110c9826d10005d3a0341b78cdee41a6ef08842716ced2b58af03f91eb1b8cc929c languageName: node linkType: hard -"@typescript-eslint/parser@npm:7.18.0": - version: 7.18.0 - resolution: "@typescript-eslint/parser@npm:7.18.0" +"@typescript-eslint/parser@npm:8.26.1": + version: 8.26.1 + resolution: "@typescript-eslint/parser@npm:8.26.1" dependencies: - "@typescript-eslint/scope-manager": "npm:7.18.0" - "@typescript-eslint/types": "npm:7.18.0" - "@typescript-eslint/typescript-estree": "npm:7.18.0" - "@typescript-eslint/visitor-keys": "npm:7.18.0" + "@typescript-eslint/scope-manager": "npm:8.26.1" + "@typescript-eslint/types": "npm:8.26.1" + "@typescript-eslint/typescript-estree": "npm:8.26.1" + "@typescript-eslint/visitor-keys": "npm:8.26.1" debug: "npm:^4.3.4" peerDependencies: - eslint: ^8.56.0 - peerDependenciesMeta: - typescript: - optional: true - checksum: 10c0/370e73fca4278091bc1b657f85e7d74cd52b24257ea20c927a8e17546107ce04fbf313fec99aed0cc2a145ddbae1d3b12e9cc2c1320117636dc1281bcfd08059 - languageName: node - linkType: hard - -"@typescript-eslint/scope-manager@npm:7.18.0": - version: 7.18.0 - resolution: "@typescript-eslint/scope-manager@npm:7.18.0" - dependencies: - "@typescript-eslint/types": "npm:7.18.0" - "@typescript-eslint/visitor-keys": "npm:7.18.0" - checksum: 10c0/038cd58c2271de146b3a594afe2c99290034033326d57ff1f902976022c8b0138ffd3cb893ae439ae41003b5e4bcc00cabf6b244ce40e8668f9412cc96d97b8e + eslint: ^8.57.0 || ^9.0.0 + typescript: ">=4.8.4 <5.9.0" + checksum: 10c0/21fe4306b6017bf183d92cdd493edacd302816071e29e1400452f3ccd224ab8111b75892507b9731545e98e6e4d153e54dab568b3433f6c9596b6cb2f7af922f languageName: node linkType: hard @@ -5371,27 +5357,28 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/type-utils@npm:7.18.0": - version: 7.18.0 - resolution: "@typescript-eslint/type-utils@npm:7.18.0" +"@typescript-eslint/scope-manager@npm:8.26.1": + version: 8.26.1 + resolution: "@typescript-eslint/scope-manager@npm:8.26.1" dependencies: - "@typescript-eslint/typescript-estree": "npm:7.18.0" - "@typescript-eslint/utils": "npm:7.18.0" - debug: "npm:^4.3.4" - ts-api-utils: "npm:^1.3.0" - peerDependencies: - eslint: ^8.56.0 - peerDependenciesMeta: - typescript: - optional: true - checksum: 10c0/ad92a38007be620f3f7036f10e234abdc2fdc518787b5a7227e55fd12896dacf56e8b34578723fbf9bea8128df2510ba8eb6739439a3879eda9519476d5783fd + "@typescript-eslint/types": "npm:8.26.1" + "@typescript-eslint/visitor-keys": "npm:8.26.1" + checksum: 10c0/ecd30eb615c7384f01cea8f2c8e8dda7507ada52ad0d002d3701bdd9d06f6d14cefb31c6c26ef55708adfaa2045a01151e8685656240268231a4bac8f792afe4 languageName: node linkType: hard -"@typescript-eslint/types@npm:7.18.0": - version: 7.18.0 - resolution: "@typescript-eslint/types@npm:7.18.0" - checksum: 10c0/eb7371ac55ca77db8e59ba0310b41a74523f17e06f485a0ef819491bc3dd8909bb930120ff7d30aaf54e888167e0005aa1337011f3663dc90fb19203ce478054 +"@typescript-eslint/type-utils@npm:8.26.1": + version: 8.26.1 + resolution: "@typescript-eslint/type-utils@npm:8.26.1" + dependencies: + "@typescript-eslint/typescript-estree": "npm:8.26.1" + "@typescript-eslint/utils": "npm:8.26.1" + debug: "npm:^4.3.4" + ts-api-utils: "npm:^2.0.1" + peerDependencies: + eslint: ^8.57.0 || ^9.0.0 + typescript: ">=4.8.4 <5.9.0" + checksum: 10c0/17553b4333246e1ffd447dab78a4cbc565c129c9baf32326387760c9790120a99d955acf84888b7ef96e73c82fc22a3e08e80f0bd65d21e3cf2fe002f977aba1 languageName: node linkType: hard @@ -5402,22 +5389,10 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/typescript-estree@npm:7.18.0": - version: 7.18.0 - resolution: "@typescript-eslint/typescript-estree@npm:7.18.0" - dependencies: - "@typescript-eslint/types": "npm:7.18.0" - "@typescript-eslint/visitor-keys": "npm:7.18.0" - debug: "npm:^4.3.4" - globby: "npm:^11.1.0" - is-glob: "npm:^4.0.3" - minimatch: "npm:^9.0.4" - semver: "npm:^7.6.0" - ts-api-utils: "npm:^1.3.0" - peerDependenciesMeta: - typescript: - optional: true - checksum: 10c0/0c7f109a2e460ec8a1524339479cf78ff17814d23c83aa5112c77fb345e87b3642616291908dcddea1e671da63686403dfb712e4a4435104f92abdfddf9aba81 +"@typescript-eslint/types@npm:8.26.1": + version: 8.26.1 + resolution: "@typescript-eslint/types@npm:8.26.1" + checksum: 10c0/805b239b57854fc12eae9e2bec6ccab24bac1d30a762c455f22c73b777a5859c64c58b4750458bd0ab4aadd664eb95cbef091348a071975acac05b15ebea9f1b languageName: node linkType: hard @@ -5439,17 +5414,36 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/utils@npm:7.18.0": - version: 7.18.0 - resolution: "@typescript-eslint/utils@npm:7.18.0" +"@typescript-eslint/typescript-estree@npm:8.26.1": + version: 8.26.1 + resolution: "@typescript-eslint/typescript-estree@npm:8.26.1" + dependencies: + "@typescript-eslint/types": "npm:8.26.1" + "@typescript-eslint/visitor-keys": "npm:8.26.1" + debug: "npm:^4.3.4" + fast-glob: "npm:^3.3.2" + is-glob: "npm:^4.0.3" + minimatch: "npm:^9.0.4" + semver: "npm:^7.6.0" + ts-api-utils: "npm:^2.0.1" + peerDependencies: + typescript: ">=4.8.4 <5.9.0" + checksum: 10c0/adc95e4735a8ded05ad35d7b4fae68c675afdd4b3531bc4a51eab5efe793cf80bc75f56dfc8022af4c0a5b316eec61f8ce6b77c2ead45fc675fea7e28cd52ade + languageName: node + linkType: hard + +"@typescript-eslint/utils@npm:8.26.1": + version: 8.26.1 + resolution: "@typescript-eslint/utils@npm:8.26.1" dependencies: "@eslint-community/eslint-utils": "npm:^4.4.0" - "@typescript-eslint/scope-manager": "npm:7.18.0" - "@typescript-eslint/types": "npm:7.18.0" - "@typescript-eslint/typescript-estree": "npm:7.18.0" + "@typescript-eslint/scope-manager": "npm:8.26.1" + "@typescript-eslint/types": "npm:8.26.1" + "@typescript-eslint/typescript-estree": "npm:8.26.1" peerDependencies: - eslint: ^8.56.0 - checksum: 10c0/a25a6d50eb45c514469a01ff01f215115a4725fb18401055a847ddf20d1b681409c4027f349033a95c4ff7138d28c3b0a70253dfe8262eb732df4b87c547bd1e + eslint: ^8.57.0 || ^9.0.0 + typescript: ">=4.8.4 <5.9.0" + checksum: 10c0/a5cb3bdf253cc8e8474a2ed8666c0a6194abe56f44039c6623bef0459ed17d0276ed6e40c70d35bd8ec4d41bafc255e4d3025469f32ac692ba2d89e7579c2a26 languageName: node linkType: hard @@ -5468,16 +5462,6 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/visitor-keys@npm:7.18.0": - version: 7.18.0 - resolution: "@typescript-eslint/visitor-keys@npm:7.18.0" - dependencies: - "@typescript-eslint/types": "npm:7.18.0" - eslint-visitor-keys: "npm:^3.4.3" - checksum: 10c0/538b645f8ff1d9debf264865c69a317074eaff0255e63d7407046176b0f6a6beba34a6c51d511f12444bae12a98c69891eb6f403c9f54c6c2e2849d1c1cb73c0 - languageName: node - linkType: hard - "@typescript-eslint/visitor-keys@npm:8.26.0": version: 8.26.0 resolution: "@typescript-eslint/visitor-keys@npm:8.26.0" @@ -5488,6 +5472,16 @@ __metadata: languageName: node linkType: hard +"@typescript-eslint/visitor-keys@npm:8.26.1": + version: 8.26.1 + resolution: "@typescript-eslint/visitor-keys@npm:8.26.1" + dependencies: + "@typescript-eslint/types": "npm:8.26.1" + eslint-visitor-keys: "npm:^4.2.0" + checksum: 10c0/51b1016d06cd2b9eac0a213de418b0a26022fd3b71478014541bfcbc2a3c4d666552390eb9c209fa9e52c868710d9f1b21a2c789d35c650239438c366a27a239 + languageName: node + linkType: hard + "@vitejs/plugin-react-swc@npm:^3.8.0": version: 3.8.0 resolution: "@vitejs/plugin-react-swc@npm:3.8.0" @@ -10184,7 +10178,7 @@ __metadata: languageName: node linkType: hard -"eslint-visitor-keys@npm:^3.3.0, eslint-visitor-keys@npm:^3.4.3": +"eslint-visitor-keys@npm:^3.3.0": version: 3.4.3 resolution: "eslint-visitor-keys@npm:3.4.3" checksum: 10c0/92708e882c0a5ffd88c23c0b404ac1628cf20104a108c745f240a13c332a11aac54f49a22d5762efbffc18ecbc9a580d1b7ad034bf5f3cc3307e5cbff2ec9820 @@ -11833,7 +11827,7 @@ __metadata: languageName: node linkType: hard -"globby@npm:11.1.0, globby@npm:^11.1.0": +"globby@npm:11.1.0": version: 11.1.0 resolution: "globby@npm:11.1.0" dependencies: @@ -21339,15 +21333,6 @@ __metadata: languageName: node linkType: hard -"ts-api-utils@npm:^1.3.0": - version: 1.4.3 - resolution: "ts-api-utils@npm:1.4.3" - peerDependencies: - typescript: ">=4.2.0" - checksum: 10c0/e65dc6e7e8141140c23e1dc94984bf995d4f6801919c71d6dc27cf0cd51b100a91ffcfe5217626193e5bea9d46831e8586febdc7e172df3f1091a7384299e23a - languageName: node - linkType: hard - "ts-api-utils@npm:^2.0.1": version: 2.0.1 resolution: "ts-api-utils@npm:2.0.1" @@ -21681,19 +21666,17 @@ __metadata: languageName: node linkType: hard -"typescript-eslint@npm:^7.18.0": - version: 7.18.0 - resolution: "typescript-eslint@npm:7.18.0" +"typescript-eslint@npm:^8.22.0": + version: 8.26.1 + resolution: "typescript-eslint@npm:8.26.1" dependencies: - "@typescript-eslint/eslint-plugin": "npm:7.18.0" - "@typescript-eslint/parser": "npm:7.18.0" - "@typescript-eslint/utils": "npm:7.18.0" + "@typescript-eslint/eslint-plugin": "npm:8.26.1" + "@typescript-eslint/parser": "npm:8.26.1" + "@typescript-eslint/utils": "npm:8.26.1" peerDependencies: - eslint: ^8.56.0 - peerDependenciesMeta: - typescript: - optional: true - checksum: 10c0/610c0faa70b9be89255086378c7ef69e979115c89be69851fb4d69e76907b3520450b162a8adee56b32dbf368f8c14c1fac88065539012140c1319851f2676da + eslint: ^8.57.0 || ^9.0.0 + typescript: ">=4.8.4 <5.9.0" + checksum: 10c0/92ab2e59950020eae9956e0e1fd572bc98bab0f764e63f49bfd9feab3b38edfe888712fd2df6fc43642b9be06e60288f72626d7a7cc25dcbb4c692df64cba064 languageName: node linkType: hard