diff --git a/eslint.config.js b/eslint.config.js index 6049ebf11..5a24819df 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -75,7 +75,7 @@ module.exports = [{ "react-hooks/rules-of-hooks": "error", "react-hooks/exhaustive-deps": "error", "unused-imports/no-unused-imports": "warn", - "unused-imports/no-unused-vars": [ + "no-unused-vars": [ "warn", { "vars": "all", "varsIgnorePattern": "^_", "args": "after-used", "argsIgnorePattern": "^_" } ] diff --git a/package.json b/package.json index a5a7ae2c9..1dd37b70a 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,7 @@ "@types/js-base64": "3.3.1", "@types/react-test-renderer": "^17.0.7", "@types/selenium-webdriver": "^4.1.26", - "@typescript-eslint/eslint-plugin": "^6.14.0", + "@typescript-eslint/eslint-plugin": "^8.6.0", "@typescript-eslint/parser": "^8.6.0", "concurrently": "^9.0.1", "css-loader": "^7.1.2", diff --git a/src/app/Dashboard/LayoutTemplateUploadModal.tsx b/src/app/Dashboard/LayoutTemplateUploadModal.tsx index ef00d6189..912b08ad8 100644 --- a/src/app/Dashboard/LayoutTemplateUploadModal.tsx +++ b/src/app/Dashboard/LayoutTemplateUploadModal.tsx @@ -68,7 +68,7 @@ export const LayoutTemplateUploadModal: React.FC let template: SerialLayoutTemplate; try { template = JSON.parse(content); - } catch (err) { + } catch (_) { throw new Error(t('LayoutTemplateUploadModal.ERROR.PARSE')); } if ( @@ -170,7 +170,7 @@ export const LayoutTemplateUploadModal: React.FC onSingleSuccess(fileUpload.file.name); } return of(template); - } catch (err) { + } catch (_) { // template name already taken from previous upload onSingleFailure( fileUpload.file.name, diff --git a/src/app/Shared/Redux/Middlewares/PersistMiddleware.tsx b/src/app/Shared/Redux/Middlewares/PersistMiddleware.tsx index 95644dcc4..aa56dcbcd 100644 --- a/src/app/Shared/Redux/Middlewares/PersistMiddleware.tsx +++ b/src/app/Shared/Redux/Middlewares/PersistMiddleware.tsx @@ -22,7 +22,6 @@ import { enumValues as RecordingFilterActions } from '../Filters/RecordingFilter import { enumValues as TopologyFilterActions } from '../Filters/TopologyFilterSlice'; import type { RootState } from '../ReduxStore'; -/* eslint-disable-next-line @typescript-eslint/ban-types*/ export const persistMiddleware: Middleware<{}, RootState> = ({ getState }) => (next) => diff --git a/src/app/utils/LocalStorage.ts b/src/app/utils/LocalStorage.ts index c571d6bf2..c78ab4717 100644 --- a/src/app/utils/LocalStorage.ts +++ b/src/app/utils/LocalStorage.ts @@ -51,7 +51,7 @@ export const getFromLocalStorage = (key: LocalStorageKeyStrings, defaultValue try { const item = window.localStorage.getItem(key); return item ? JSON.parse(item) : defaultValue; - } catch (error) { + } catch (_) { return defaultValue; } }; diff --git a/yarn.lock b/yarn.lock index b37a13c4e..4a084bcdd 100644 --- a/yarn.lock +++ b/yarn.lock @@ -746,10 +746,10 @@ __metadata: languageName: node linkType: hard -"@eslint-community/regexpp@npm:^4.5.1": - version: 4.8.0 - resolution: "@eslint-community/regexpp@npm:4.8.0" - checksum: 601e6d033d556e98e8c929905bef335f20d7389762812df4d0f709d9b4d2631610dda975fb272e23b5b68e24a163b3851b114c8080a0a19fb4c141a1eff6305b +"@eslint-community/regexpp@npm:^4.10.0": + version: 4.11.1 + resolution: "@eslint-community/regexpp@npm:4.11.1" + checksum: 6986685529d30e33c2640973c3d8e7ddd31bef3cc8cb10ad54ddc1dea12680779a2c23a45562aa1462c488137a3570e672d122fac7da22d82294382d915cec70 languageName: node linkType: hard @@ -2362,13 +2362,6 @@ __metadata: languageName: node linkType: hard -"@types/json-schema@npm:^7.0.12": - version: 7.0.12 - resolution: "@types/json-schema@npm:7.0.12" - checksum: 00239e97234eeb5ceefb0c1875d98ade6e922bfec39dd365ec6bd360b5c2f825e612ac4f6e5f1d13601b8b30f378f15e6faa805a3a732f4a1bbe61915163d293 - languageName: node - linkType: hard - "@types/json5@npm:^0.0.29": version: 0.0.29 resolution: "@types/json5@npm:0.0.29" @@ -2517,13 +2510,6 @@ __metadata: languageName: node linkType: hard -"@types/semver@npm:^7.5.0": - version: 7.5.1 - resolution: "@types/semver@npm:7.5.1" - checksum: 2fffe938c7ac168711f245a16e1856a3578d77161ca17e29a05c3e02c7be3e9c5beefa29a3350f6c1bd982fb70aa28cc52e4845eb7d36246bcdc0377170d584d - languageName: node - linkType: hard - "@types/send@npm:*": version: 0.17.4 resolution: "@types/send@npm:0.17.4" @@ -2637,28 +2623,26 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/eslint-plugin@npm:^6.14.0": - version: 6.14.0 - resolution: "@typescript-eslint/eslint-plugin@npm:6.14.0" +"@typescript-eslint/eslint-plugin@npm:^8.6.0": + version: 8.6.0 + resolution: "@typescript-eslint/eslint-plugin@npm:8.6.0" dependencies: - "@eslint-community/regexpp": ^4.5.1 - "@typescript-eslint/scope-manager": 6.14.0 - "@typescript-eslint/type-utils": 6.14.0 - "@typescript-eslint/utils": 6.14.0 - "@typescript-eslint/visitor-keys": 6.14.0 - debug: ^4.3.4 + "@eslint-community/regexpp": ^4.10.0 + "@typescript-eslint/scope-manager": 8.6.0 + "@typescript-eslint/type-utils": 8.6.0 + "@typescript-eslint/utils": 8.6.0 + "@typescript-eslint/visitor-keys": 8.6.0 graphemer: ^1.4.0 - ignore: ^5.2.4 + ignore: ^5.3.1 natural-compare: ^1.4.0 - semver: ^7.5.4 - ts-api-utils: ^1.0.1 + ts-api-utils: ^1.3.0 peerDependencies: - "@typescript-eslint/parser": ^6.0.0 || ^6.0.0-alpha - eslint: ^7.0.0 || ^8.0.0 + "@typescript-eslint/parser": ^8.0.0 || ^8.0.0-alpha.0 + eslint: ^8.57.0 || ^9.0.0 peerDependenciesMeta: typescript: optional: true - checksum: ec688fd71b21576bfe0e4176889fddf3c13d8b07792461b84017d689ed11a9bffbf4d2ab61e9bdb254e43d2c1e159d5c2fc21bdfa6a6c2d64f9e1956a668fbe8 + checksum: 6acab71c3066b86ba19b081c44b7060df4468d932813a94ad3b60f0f88b78b97f3555a0605814e32f8399737c0789e72cb509a6cf6d70e4823a7cc8769d06fa4 languageName: node linkType: hard @@ -2680,16 +2664,6 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/scope-manager@npm:6.14.0": - version: 6.14.0 - resolution: "@typescript-eslint/scope-manager@npm:6.14.0" - dependencies: - "@typescript-eslint/types": 6.14.0 - "@typescript-eslint/visitor-keys": 6.14.0 - checksum: 0b577d42db925426a9838fe61703c226e18b697374fbe20cf9b93ba30fe58bf4a7f7f42491a4d24b7f3cc12d9a189fe3524c0e9b7708727e710d95b908250a14 - languageName: node - linkType: hard - "@typescript-eslint/scope-manager@npm:8.6.0": version: 8.6.0 resolution: "@typescript-eslint/scope-manager@npm:8.6.0" @@ -2700,27 +2674,18 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/type-utils@npm:6.14.0": - version: 6.14.0 - resolution: "@typescript-eslint/type-utils@npm:6.14.0" +"@typescript-eslint/type-utils@npm:8.6.0": + version: 8.6.0 + resolution: "@typescript-eslint/type-utils@npm:8.6.0" dependencies: - "@typescript-eslint/typescript-estree": 6.14.0 - "@typescript-eslint/utils": 6.14.0 + "@typescript-eslint/typescript-estree": 8.6.0 + "@typescript-eslint/utils": 8.6.0 debug: ^4.3.4 - ts-api-utils: ^1.0.1 - peerDependencies: - eslint: ^7.0.0 || ^8.0.0 + ts-api-utils: ^1.3.0 peerDependenciesMeta: typescript: optional: true - checksum: 09988f25279598840673c41ba44b03756f2dfb31284ab72af97c170711a0f31e5c53d6b120aa83f31438565e82aae1a1ca4d1ed0de4890654dd6a6a33d88202c - languageName: node - linkType: hard - -"@typescript-eslint/types@npm:6.14.0": - version: 6.14.0 - resolution: "@typescript-eslint/types@npm:6.14.0" - checksum: 624e6c5227f596dcc9757348d09c5a09b846a62938b8b4409614cf8108013b64ed8b270c32e87ea8890dd09ed896b82e92872c3574dbf07dcda11a168d69dd1f + checksum: d395745176cc13d96759e4ad7b698058f4fc24b62d0bd3fe603f49546f369cbf3e46fefbcc6069c33b1b0d825e033e0a5a972fd0b1a05f7ce9e8588154a02b93 languageName: node linkType: hard @@ -2731,24 +2696,6 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/typescript-estree@npm:6.14.0": - version: 6.14.0 - resolution: "@typescript-eslint/typescript-estree@npm:6.14.0" - dependencies: - "@typescript-eslint/types": 6.14.0 - "@typescript-eslint/visitor-keys": 6.14.0 - debug: ^4.3.4 - globby: ^11.1.0 - is-glob: ^4.0.3 - semver: ^7.5.4 - ts-api-utils: ^1.0.1 - peerDependenciesMeta: - typescript: - optional: true - checksum: 495d7616463685bfd8138ffa9fbc0a7f9130ff8a3f6f85775960b4f0a3fdc259ae53b104cdfe562b60310860b5a6c8387307790734555084aa087e3bb9c28a69 - languageName: node - linkType: hard - "@typescript-eslint/typescript-estree@npm:8.6.0": version: 8.6.0 resolution: "@typescript-eslint/typescript-estree@npm:8.6.0" @@ -2768,30 +2715,17 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/utils@npm:6.14.0": - version: 6.14.0 - resolution: "@typescript-eslint/utils@npm:6.14.0" +"@typescript-eslint/utils@npm:8.6.0": + version: 8.6.0 + resolution: "@typescript-eslint/utils@npm:8.6.0" dependencies: "@eslint-community/eslint-utils": ^4.4.0 - "@types/json-schema": ^7.0.12 - "@types/semver": ^7.5.0 - "@typescript-eslint/scope-manager": 6.14.0 - "@typescript-eslint/types": 6.14.0 - "@typescript-eslint/typescript-estree": 6.14.0 - semver: ^7.5.4 + "@typescript-eslint/scope-manager": 8.6.0 + "@typescript-eslint/types": 8.6.0 + "@typescript-eslint/typescript-estree": 8.6.0 peerDependencies: - eslint: ^7.0.0 || ^8.0.0 - checksum: 36e8501cb85647947189f31017c36d6f6ac7ef0399fa0e18eb64f1b83e00f1e8ace1d9ac5015ef4d9c1b820179f1def8d61d7ea9e5d61433eb848cf5c49dc8b0 - languageName: node - linkType: hard - -"@typescript-eslint/visitor-keys@npm:6.14.0": - version: 6.14.0 - resolution: "@typescript-eslint/visitor-keys@npm:6.14.0" - dependencies: - "@typescript-eslint/types": 6.14.0 - eslint-visitor-keys: ^3.4.1 - checksum: fc593c4e94d5739be7bd88e42313a301bc9806fad758b6a0a1bafd296ff41522be602caf4976beec84e363b0f56585bb98df3c157f70de984de721798501fd8a + eslint: ^8.57.0 || ^9.0.0 + checksum: dbb2efe47c291d36d5ec147f8c8fe62d27e9db2a3368aefd9019fd1e118bd1a54c8b13b990bb0941c9510bc4e2049b336e9a26d6414a6239c020e36baa8797e2 languageName: node linkType: hard @@ -4463,7 +4397,7 @@ __metadata: "@types/react": ^17.0.69 "@types/react-test-renderer": ^17.0.7 "@types/selenium-webdriver": ^4.1.26 - "@typescript-eslint/eslint-plugin": ^6.14.0 + "@typescript-eslint/eslint-plugin": ^8.6.0 "@typescript-eslint/parser": ^8.6.0 concurrently: ^9.0.1 css-loader: ^7.1.2 @@ -6610,7 +6544,7 @@ __metadata: languageName: node linkType: hard -"fast-glob@npm:^3.0.3, fast-glob@npm:^3.2.9": +"fast-glob@npm:^3.0.3": version: 3.2.12 resolution: "fast-glob@npm:3.2.12" dependencies: @@ -7302,20 +7236,6 @@ __metadata: languageName: node linkType: hard -"globby@npm:^11.1.0": - version: 11.1.0 - resolution: "globby@npm:11.1.0" - dependencies: - array-union: ^2.1.0 - dir-glob: ^3.0.1 - fast-glob: ^3.2.9 - ignore: ^5.2.0 - merge2: ^1.4.1 - slash: ^3.0.0 - checksum: b4be8885e0cfa018fc783792942d53926c35c50b3aefd3fdcfb9d22c627639dc26bd2327a40a0b74b074100ce95bb7187bfeae2f236856aa3de183af7a02aea6 - languageName: node - linkType: hard - "globby@npm:^14.0.1": version: 14.0.2 resolution: "globby@npm:14.0.2" @@ -7906,6 +7826,13 @@ __metadata: languageName: node linkType: hard +"ignore@npm:^5.3.1": + version: 5.3.2 + resolution: "ignore@npm:5.3.2" + checksum: 2acfd32a573260ea522ea0bfeff880af426d68f6831f973129e2ba7363f422923cf53aab62f8369cbf4667c7b25b6f8a3761b34ecdb284ea18e87a5262a865be + languageName: node + linkType: hard + "imagemin@npm:^9.0.0": version: 9.0.0 resolution: "imagemin@npm:9.0.0" @@ -9791,7 +9718,7 @@ __metadata: languageName: node linkType: hard -"merge2@npm:^1.2.3, merge2@npm:^1.3.0, merge2@npm:^1.4.1": +"merge2@npm:^1.2.3, merge2@npm:^1.3.0": version: 1.4.1 resolution: "merge2@npm:1.4.1" checksum: 7268db63ed5169466540b6fb947aec313200bcf6d40c5ab722c22e242f651994619bcd85601602972d3c85bd2cc45a358a4c61937e9f11a061919a1da569b0c2 @@ -13582,15 +13509,6 @@ __metadata: languageName: node linkType: hard -"ts-api-utils@npm:^1.0.1": - version: 1.0.2 - resolution: "ts-api-utils@npm:1.0.2" - peerDependencies: - typescript: ">=4.2.0" - checksum: 6375e12ba90b6cbe73f564405248da14c52aa44b62b386e1cbbb1da2640265dd33e99d3e019688dffa874e365cf596b161ccd49351e90638be825c2639697640 - languageName: node - linkType: hard - "ts-api-utils@npm:^1.3.0": version: 1.3.0 resolution: "ts-api-utils@npm:1.3.0"