diff --git a/core.js b/core.js index 953ac23..01eade1 100644 --- a/core.js +++ b/core.js @@ -29,6 +29,7 @@ module.exports = { 'eslint-comments', ], 'rules': { + '@rimac-technology/class-element-sorting': 'error', '@rimac-technology/document-todos': [ 'error', { url: 'https://rimac-automobili.atlassian.net' }, diff --git a/package.json b/package.json index fb93a41..09f6ebb 100644 --- a/package.json +++ b/package.json @@ -36,7 +36,7 @@ "eslint": "^8" }, "dependencies": { - "@rimac-technology/eslint-plugin": "^1.1.0", + "@rimac-technology/eslint-plugin": "^1.2.0", "@typescript-eslint/eslint-plugin": "^5.36.2", "@typescript-eslint/parser": "^5.36.2", "eslint-plugin-eslint-comments": "^3.2.0", diff --git a/yarn.lock b/yarn.lock index 39e755d..8e4731a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1817,14 +1817,47 @@ __metadata: languageName: node linkType: hard -"@rimac-technology/eslint-config@^26.0.0, @rimac-technology/eslint-config@workspace:.": +"@rimac-technology/eslint-config@npm:^26.0.0": + version: 26.0.1 + resolution: "@rimac-technology/eslint-config@npm:26.0.1" + dependencies: + "@rimac-technology/eslint-plugin": ^1.1.0 + "@typescript-eslint/eslint-plugin": ^5.30.6 + "@typescript-eslint/parser": ^5.30.6 + eslint-plugin-eslint-comments: ^3.2.0 + eslint-plugin-etc: ^2.0.2 + eslint-plugin-import: ^2.26.0 + eslint-plugin-jest: ^26.5.3 + eslint-plugin-jest-formatting: ^3.1.0 + eslint-plugin-mobx: ^0.0.9 + eslint-plugin-more: ^1.0.5 + eslint-plugin-promise: ^6.0.0 + eslint-plugin-react: ^7.30.1 + eslint-plugin-react-hooks: ^4.6.0 + eslint-plugin-sonarjs: ^0.13.0 + eslint-plugin-sort-class-members: ^1.14.1 + eslint-plugin-sort-destructure-keys: ^1.4.0 + eslint-plugin-sort-keys-fix: ^1.1.2 + eslint-plugin-testing-library: ^5.5.1 + eslint-plugin-type-graphql: ^1.0.0 + eslint-plugin-typescript-sort-keys: ^2.1.0 + eslint-plugin-unicorn: ^43.0.1 + eslint-plugin-unused-imports: ^2.0.0 + eslint-plugin-workspaces: ^0.7.0 + peerDependencies: + eslint: ^8 + checksum: ca09576e37d05795a5c280e7b182ad1a6b36a671296ebb8e5a83df09793ec142d0fd6929156a3143cb3e0c6d20410759b6a8cf3014e1191e973be6af4602b033 + languageName: node + linkType: hard + +"@rimac-technology/eslint-config@workspace:.": version: 0.0.0-use.local resolution: "@rimac-technology/eslint-config@workspace:." dependencies: "@commitlint/cli": ^17.1.2 "@commitlint/config-conventional": ^17.1.0 "@rimac-technology/eslint-config": ^26.0.0 - "@rimac-technology/eslint-plugin": ^1.1.0 + "@rimac-technology/eslint-plugin": ^1.2.0 "@semantic-release/changelog": ^6.0.1 "@semantic-release/commit-analyzer": ^9.0.2 "@semantic-release/git": ^10.0.1 @@ -1876,6 +1909,15 @@ __metadata: languageName: node linkType: hard +"@rimac-technology/eslint-plugin@npm:^1.2.0": + version: 1.2.0 + resolution: "@rimac-technology/eslint-plugin@npm:1.2.0" + dependencies: + "@typescript-eslint/types": ^5.19.0 + checksum: 4fc73d90e84ad9bd0aaccc2be077fb9f0a502c539679e18761db7cb8652d297ba475d1fda9f751add716e46479aadb9b7af21c2179b0e2ab885155b1d1fe694b + languageName: node + linkType: hard + "@semantic-release/changelog@npm:^6.0.1": version: 6.0.1 resolution: "@semantic-release/changelog@npm:6.0.1" @@ -2271,6 +2313,28 @@ __metadata: languageName: node linkType: hard +"@typescript-eslint/eslint-plugin@npm:^5.30.6": + version: 5.38.0 + resolution: "@typescript-eslint/eslint-plugin@npm:5.38.0" + dependencies: + "@typescript-eslint/scope-manager": 5.38.0 + "@typescript-eslint/type-utils": 5.38.0 + "@typescript-eslint/utils": 5.38.0 + debug: ^4.3.4 + ignore: ^5.2.0 + regexpp: ^3.2.0 + semver: ^7.3.7 + tsutils: ^3.21.0 + peerDependencies: + "@typescript-eslint/parser": ^5.0.0 + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: e9cd1970c7c8a438aee912cf00aa27bdcde0a0fb57bbfe70eccda93eefa5b4fb4c7ebf5ba7a51744c1ec2b4df3a72b8dcd19dc17a9c3e4e3435f631ac6b10a6a + languageName: node + linkType: hard + "@typescript-eslint/eslint-plugin@npm:^5.36.2": version: 5.36.2 resolution: "@typescript-eslint/eslint-plugin@npm:5.36.2" @@ -2321,6 +2385,23 @@ __metadata: languageName: node linkType: hard +"@typescript-eslint/parser@npm:^5.30.6": + version: 5.38.0 + resolution: "@typescript-eslint/parser@npm:5.38.0" + dependencies: + "@typescript-eslint/scope-manager": 5.38.0 + "@typescript-eslint/types": 5.38.0 + "@typescript-eslint/typescript-estree": 5.38.0 + debug: ^4.3.4 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: d5fb2d8f3a25cd6ff31326c665db4617f2d428247cad690f0404de440abbcfc7261528f54d642d2b121aae34aadecb55a24b72c8ef341cafdc7b2bbcbf7dae8d + languageName: node + linkType: hard + "@typescript-eslint/parser@npm:^5.36.2": version: 5.36.2 resolution: "@typescript-eslint/parser@npm:5.36.2" @@ -2378,6 +2459,16 @@ __metadata: languageName: node linkType: hard +"@typescript-eslint/scope-manager@npm:5.38.0": + version: 5.38.0 + resolution: "@typescript-eslint/scope-manager@npm:5.38.0" + dependencies: + "@typescript-eslint/types": 5.38.0 + "@typescript-eslint/visitor-keys": 5.38.0 + checksum: a34d2976e9c755b853b6524e0b9fb1da237340ddff9f6839a51ba37998527c02d0f2f16ffc3d4baa47898f2bb7eb85a6749d6ca588c0461dbd654d8f9925dd0f + languageName: node + linkType: hard + "@typescript-eslint/type-utils@npm:5.36.2": version: 5.36.2 resolution: "@typescript-eslint/type-utils@npm:5.36.2" @@ -2395,6 +2486,23 @@ __metadata: languageName: node linkType: hard +"@typescript-eslint/type-utils@npm:5.38.0": + version: 5.38.0 + resolution: "@typescript-eslint/type-utils@npm:5.38.0" + dependencies: + "@typescript-eslint/typescript-estree": 5.38.0 + "@typescript-eslint/utils": 5.38.0 + debug: ^4.3.4 + tsutils: ^3.21.0 + peerDependencies: + eslint: "*" + peerDependenciesMeta: + typescript: + optional: true + checksum: 43f2f55329b2357bedf158a93a469d058a11c69f8f88ff891080b8cb5977bffe8d679923bce7048cbc076c083e0f5741c83b761355309d606cc4e217e1da4208 + languageName: node + linkType: hard + "@typescript-eslint/types@npm:5.10.2": version: 5.10.2 resolution: "@typescript-eslint/types@npm:5.10.2" @@ -2423,6 +2531,13 @@ __metadata: languageName: node linkType: hard +"@typescript-eslint/types@npm:5.38.0": + version: 5.38.0 + resolution: "@typescript-eslint/types@npm:5.38.0" + checksum: 03aec1de64417e60830c6d33bb4f1bf4402411080371013513f55c7a2fadb6f8745a89a7604cde03d89aa53307f94bc913060c5897ed93285247e4c39af43a00 + languageName: node + linkType: hard + "@typescript-eslint/types@npm:^5.19.0": version: 5.19.0 resolution: "@typescript-eslint/types@npm:5.19.0" @@ -2502,6 +2617,24 @@ __metadata: languageName: node linkType: hard +"@typescript-eslint/typescript-estree@npm:5.38.0": + version: 5.38.0 + resolution: "@typescript-eslint/typescript-estree@npm:5.38.0" + dependencies: + "@typescript-eslint/types": 5.38.0 + "@typescript-eslint/visitor-keys": 5.38.0 + debug: ^4.3.4 + globby: ^11.1.0 + is-glob: ^4.0.3 + semver: ^7.3.7 + tsutils: ^3.21.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: 174461c91e49a0340945da2d31e38ec175cd90b2b5068f3c925518cc9182100fe1435d3225908a52f62257e97bc2b995cbc6b6bd1b7143ff0a0e4b483bd70834 + languageName: node + linkType: hard + "@typescript-eslint/utils@npm:5.10.2, @typescript-eslint/utils@npm:^5.10.0": version: 5.10.2 resolution: "@typescript-eslint/utils@npm:5.10.2" @@ -2534,6 +2667,22 @@ __metadata: languageName: node linkType: hard +"@typescript-eslint/utils@npm:5.38.0": + version: 5.38.0 + resolution: "@typescript-eslint/utils@npm:5.38.0" + dependencies: + "@types/json-schema": ^7.0.9 + "@typescript-eslint/scope-manager": 5.38.0 + "@typescript-eslint/types": 5.38.0 + "@typescript-eslint/typescript-estree": 5.38.0 + eslint-scope: ^5.1.1 + eslint-utils: ^3.0.0 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + checksum: c927a68d4ff5029ed3dbc7e6e87702f7cdfba26452ccf401b37cc68f6e5cca72eb884831dbc7957512998d59950b1852b2ecea19f174a20fe659d851b4afd4fd + languageName: node + linkType: hard + "@typescript-eslint/utils@npm:^5.13.0": version: 5.14.0 resolution: "@typescript-eslint/utils@npm:5.14.0" @@ -2590,6 +2739,16 @@ __metadata: languageName: node linkType: hard +"@typescript-eslint/visitor-keys@npm:5.38.0": + version: 5.38.0 + resolution: "@typescript-eslint/visitor-keys@npm:5.38.0" + dependencies: + "@typescript-eslint/types": 5.38.0 + eslint-visitor-keys: ^3.3.0 + checksum: cc3d0c6eb0c9a20a25d66b640d759cb1b52f8df485f16d948218d63d798b5c0672ef298f5dae5e5327ec021c0f8369d1da5d26b9c16a245a20fa44a9365956bc + languageName: node + linkType: hard + "JSONStream@npm:^1.0.4": version: 1.3.5 resolution: "JSONStream@npm:1.3.5" @@ -4486,6 +4645,23 @@ __metadata: languageName: node linkType: hard +"eslint-plugin-jest@npm:^26.5.3": + version: 26.9.0 + resolution: "eslint-plugin-jest@npm:26.9.0" + dependencies: + "@typescript-eslint/utils": ^5.10.0 + peerDependencies: + "@typescript-eslint/eslint-plugin": ^5.0.0 + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + "@typescript-eslint/eslint-plugin": + optional: true + jest: + optional: true + checksum: 6d5fd5c95368f1ca2640389aeb7ce703d6202493c3ec6bdedb4eaca37233710508b0c75829e727765a16fd27029a466d34202bc7f2811c752038ccbbce224400 + languageName: node + linkType: hard + "eslint-plugin-jest@npm:^27.0.1": version: 27.0.1 resolution: "eslint-plugin-jest@npm:27.0.1" @@ -4521,7 +4697,7 @@ __metadata: languageName: node linkType: hard -"eslint-plugin-promise@npm:^6.0.1": +"eslint-plugin-promise@npm:^6.0.0, eslint-plugin-promise@npm:^6.0.1": version: 6.0.1 resolution: "eslint-plugin-promise@npm:6.0.1" peerDependencies: @@ -4539,6 +4715,30 @@ __metadata: languageName: node linkType: hard +"eslint-plugin-react@npm:^7.30.1": + version: 7.31.8 + resolution: "eslint-plugin-react@npm:7.31.8" + dependencies: + array-includes: ^3.1.5 + array.prototype.flatmap: ^1.3.0 + doctrine: ^2.1.0 + estraverse: ^5.3.0 + jsx-ast-utils: ^2.4.1 || ^3.0.0 + minimatch: ^3.1.2 + object.entries: ^1.1.5 + object.fromentries: ^2.0.5 + object.hasown: ^1.1.1 + object.values: ^1.1.5 + prop-types: ^15.8.1 + resolve: ^2.0.0-next.3 + semver: ^6.3.0 + string.prototype.matchall: ^4.0.7 + peerDependencies: + eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 + checksum: 0683e2a624a4df6f08264a3f6bc614a81e8f961c83173bdf2d8d3523f84ed5d234cddc976dbc6815913e007c5984df742ba61be0c0592b27c3daabe0f68165a3 + languageName: node + linkType: hard + "eslint-plugin-react@npm:^7.31.7": version: 7.31.7 resolution: "eslint-plugin-react@npm:7.31.7" @@ -4563,6 +4763,15 @@ __metadata: languageName: node linkType: hard +"eslint-plugin-sonarjs@npm:^0.13.0": + version: 0.13.0 + resolution: "eslint-plugin-sonarjs@npm:0.13.0" + peerDependencies: + eslint: ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0 + checksum: f1cbb33b010c663150c3866e5fdbad2398658e279405d863f48da98edb0438b0ea68732e263f5c939d3d6f2d9a785f80c10234c1b229873b6ee44c24fd6e0cd1 + languageName: node + linkType: hard + "eslint-plugin-sonarjs@npm:^0.15.0": version: 0.15.0 resolution: "eslint-plugin-sonarjs@npm:0.15.0" @@ -4572,7 +4781,7 @@ __metadata: languageName: node linkType: hard -"eslint-plugin-sort-class-members@npm:^1.15.2": +"eslint-plugin-sort-class-members@npm:^1.14.1, eslint-plugin-sort-class-members@npm:^1.15.2": version: 1.15.2 resolution: "eslint-plugin-sort-class-members@npm:1.15.2" peerDependencies: @@ -4604,6 +4813,17 @@ __metadata: languageName: node linkType: hard +"eslint-plugin-testing-library@npm:^5.5.1": + version: 5.7.0 + resolution: "eslint-plugin-testing-library@npm:5.7.0" + dependencies: + "@typescript-eslint/utils": ^5.13.0 + peerDependencies: + eslint: ^7.5.0 || ^8.0.0 + checksum: bd181266bb65692ce03283db0b15c20baca8a4673d046f89cda40e8dd987df686545593f26afd6dc73c3226af28e3dfa338e40ec6af351095c70c6384b33eba7 + languageName: node + linkType: hard + "eslint-plugin-testing-library@npm:^5.6.1": version: 5.6.1 resolution: "eslint-plugin-testing-library@npm:5.6.1" @@ -4642,7 +4862,7 @@ __metadata: languageName: node linkType: hard -"eslint-plugin-unicorn@npm:^43.0.2": +"eslint-plugin-unicorn@npm:^43.0.1, eslint-plugin-unicorn@npm:^43.0.2": version: 43.0.2 resolution: "eslint-plugin-unicorn@npm:43.0.2" dependencies: