Skip to content

Commit b038642

Browse files
committed
chore: migrated eslint config to meet upgraded new version reqs
1 parent ba8cc4c commit b038642

File tree

4 files changed

+168
-21
lines changed

4 files changed

+168
-21
lines changed

.eslintrc.js

Lines changed: 0 additions & 14 deletions
This file was deleted.

eslint.config.js

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
const airbnbBase = require('eslint-config-airbnb-base');
2+
const prettier = require('prettier');
3+
const globals = require('globals');
4+
const jestPlugin = require('eslint-plugin-jest');
5+
6+
module.exports = [
7+
{
8+
languageOptions: {
9+
ecmaVersion: 'latest',
10+
globals: {
11+
...globals.commonjs,
12+
...globals.es2021,
13+
...globals.node,
14+
...globals.jest,
15+
jest: true,
16+
describe: true,
17+
it: true,
18+
expect: true,
19+
beforeEach: true,
20+
afterEach: true,
21+
},
22+
},
23+
plugins: {
24+
jest: jestPlugin,
25+
prettier: prettier,
26+
airbnbBase,
27+
},
28+
files: ['**/*.js', '**/*.ts'],
29+
rules: {
30+
'jest/expect-expect': 'error',
31+
},
32+
},
33+
];

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"scripts": {
77
"test": "jest --forceExit",
88
"test:dev": "jest --watch ",
9-
"lint": "eslint --ext .js,.ts ",
9+
"lint": "eslint ",
1010
"format": "prettier --write ",
1111
"prepare": "node -e \"if (process.env.NODE_ENV !== 'production'){process.exit(1)} \" || husky"
1212
},
@@ -29,6 +29,7 @@
2929
"eslint-config-airbnb-base": "^15.0.0",
3030
"eslint-config-prettier": "^10.0.1",
3131
"eslint-plugin-import": "^2.31.0",
32+
"eslint-plugin-jest": "^28.11.0",
3233
"husky": "^9.1.7",
3334
"jest": "^29.7.0",
3435
"lint-staged": "^15.4.1",
@@ -50,4 +51,4 @@
5051
"utils"
5152
]
5253
}
53-
}
54+
}

yarn.lock

Lines changed: 132 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@
322322
"@types/conventional-commits-parser" "^5.0.0"
323323
chalk "^5.3.0"
324324

325-
"@eslint-community/eslint-utils@^4.2.0":
325+
"@eslint-community/eslint-utils@^4.2.0", "@eslint-community/eslint-utils@^4.4.0":
326326
version "4.4.1"
327327
resolved "https://registry.yarnpkg.com/@eslint-community/eslint-utils/-/eslint-utils-4.4.1.tgz#d1145bf2c20132d6400495d6df4bf59362fd9d56"
328328
integrity sha512-s3O3waFUrMV8P/XaF/+ZTp1X9XBZW1a4B97ZnjQF2KYWaFD2A8KyFBsrsfSjEmjn3RGWAIuvlneuZm3CUK3jbA==
@@ -651,6 +651,27 @@
651651
"@jridgewell/resolve-uri" "^3.1.0"
652652
"@jridgewell/sourcemap-codec" "^1.4.14"
653653

654+
"@nodelib/fs.scandir@2.1.5":
655+
version "2.1.5"
656+
resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5"
657+
integrity sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==
658+
dependencies:
659+
"@nodelib/fs.stat" "2.0.5"
660+
run-parallel "^1.1.9"
661+
662+
"@nodelib/fs.stat@2.0.5", "@nodelib/fs.stat@^2.0.2":
663+
version "2.0.5"
664+
resolved "https://registry.yarnpkg.com/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz#5bd262af94e9d25bd1e71b05deed44876a222e8b"
665+
integrity sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==
666+
667+
"@nodelib/fs.walk@^1.2.3":
668+
version "1.2.8"
669+
resolved "https://registry.yarnpkg.com/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz#e95737e8bb6746ddedf69c556953494f196fe69a"
670+
integrity sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==
671+
dependencies:
672+
"@nodelib/fs.scandir" "2.1.5"
673+
fastq "^1.6.0"
674+
654675
"@rtsao/scc@^1.1.0":
655676
version "1.1.0"
656677
resolved "https://registry.yarnpkg.com/@rtsao/scc/-/scc-1.1.0.tgz#927dd2fae9bc3361403ac2c7a00c32ddce9ad7e8"
@@ -788,6 +809,51 @@
788809
dependencies:
789810
"@types/yargs-parser" "*"
790811

812+
"@typescript-eslint/scope-manager@8.20.0":
813+
version "8.20.0"
814+
resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-8.20.0.tgz#aaf4198b509fb87a6527c02cfbfaf8901179e75c"
815+
integrity sha512-J7+VkpeGzhOt3FeG1+SzhiMj9NzGD/M6KoGn9f4dbz3YzK9hvbhVTmLj/HiTp9DazIzJ8B4XcM80LrR9Dm1rJw==
816+
dependencies:
817+
"@typescript-eslint/types" "8.20.0"
818+
"@typescript-eslint/visitor-keys" "8.20.0"
819+
820+
"@typescript-eslint/types@8.20.0":
821+
version "8.20.0"
822+
resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-8.20.0.tgz#487de5314b5415dee075e95568b87a75a3e730cf"
823+
integrity sha512-cqaMiY72CkP+2xZRrFt3ExRBu0WmVitN/rYPZErA80mHjHx/Svgp8yfbzkJmDoQ/whcytOPO9/IZXnOc+wigRA==
824+
825+
"@typescript-eslint/typescript-estree@8.20.0":
826+
version "8.20.0"
827+
resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-8.20.0.tgz#658cea07b7e5981f19bce5cf1662cb70ad59f26b"
828+
integrity sha512-Y7ncuy78bJqHI35NwzWol8E0X7XkRVS4K4P4TCyzWkOJih5NDvtoRDW4Ba9YJJoB2igm9yXDdYI/+fkiiAxPzA==
829+
dependencies:
830+
"@typescript-eslint/types" "8.20.0"
831+
"@typescript-eslint/visitor-keys" "8.20.0"
832+
debug "^4.3.4"
833+
fast-glob "^3.3.2"
834+
is-glob "^4.0.3"
835+
minimatch "^9.0.4"
836+
semver "^7.6.0"
837+
ts-api-utils "^2.0.0"
838+
839+
"@typescript-eslint/utils@^6.0.0 || ^7.0.0 || ^8.0.0":
840+
version "8.20.0"
841+
resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-8.20.0.tgz#53127ecd314b3b08836b4498b71cdb86f4ef3aa2"
842+
integrity sha512-dq70RUw6UK9ei7vxc4KQtBRk7qkHZv447OUZ6RPQMQl71I3NZxQJX/f32Smr+iqWrB02pHKn2yAdHBb0KNrRMA==
843+
dependencies:
844+
"@eslint-community/eslint-utils" "^4.4.0"
845+
"@typescript-eslint/scope-manager" "8.20.0"
846+
"@typescript-eslint/types" "8.20.0"
847+
"@typescript-eslint/typescript-estree" "8.20.0"
848+
849+
"@typescript-eslint/visitor-keys@8.20.0":
850+
version "8.20.0"
851+
resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-8.20.0.tgz#2df6e24bc69084b81f06aaaa48d198b10d382bed"
852+
integrity sha512-v/BpkeeYAsPkKCkR8BDwcno0llhzWVqPOamQrAEMdpZav2Y9OVjd9dwJyBLJWwf335B5DmlifECIkZRJCaGaHA==
853+
dependencies:
854+
"@typescript-eslint/types" "8.20.0"
855+
eslint-visitor-keys "^4.2.0"
856+
791857
"@webtorrent/http-node@^1.3.0":
792858
version "1.3.0"
793859
resolved "https://registry.yarnpkg.com/@webtorrent/http-node/-/http-node-1.3.0.tgz#bd8aacf13f08bb19ee25b5f5364e8d261eaa5c3c"
@@ -1200,6 +1266,13 @@ brace-expansion@^1.1.7:
12001266
balanced-match "^1.0.0"
12011267
concat-map "0.0.1"
12021268

1269+
brace-expansion@^2.0.1:
1270+
version "2.0.1"
1271+
resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-2.0.1.tgz#1edc459e0f0c548486ecf9fc99f2221364b9a0ae"
1272+
integrity sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==
1273+
dependencies:
1274+
balanced-match "^1.0.0"
1275+
12031276
braces@^3.0.3:
12041277
version "3.0.3"
12051278
resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.3.tgz#490332f40919452272d55a8480adc0c441358789"
@@ -2051,6 +2124,13 @@ eslint-plugin-import@^2.31.0:
20512124
string.prototype.trimend "^1.0.8"
20522125
tsconfig-paths "^3.15.0"
20532126

2127+
eslint-plugin-jest@^28.11.0:
2128+
version "28.11.0"
2129+
resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-28.11.0.tgz#2641ecb4411941bbddb3d7cf8a8ff1163fbb510e"
2130+
integrity sha512-QAfipLcNCWLVocVbZW8GimKn5p5iiMcgGbRzz8z/P5q7xw+cNEpYqyzFMtIF/ZgF2HLOyy+dYBut+DoYolvqig==
2131+
dependencies:
2132+
"@typescript-eslint/utils" "^6.0.0 || ^7.0.0 || ^8.0.0"
2133+
20542134
eslint-scope@^8.2.0:
20552135
version "8.2.0"
20562136
resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-8.2.0.tgz#377aa6f1cb5dc7592cfd0b7f892fd0cf352ce442"
@@ -2237,6 +2317,17 @@ fast-fifo@^1.3.2:
22372317
resolved "https://registry.yarnpkg.com/fast-fifo/-/fast-fifo-1.3.2.tgz#286e31de96eb96d38a97899815740ba2a4f3640c"
22382318
integrity sha512-/d9sfos4yxzpwkDkuN7k2SqFKtYNmCTzgfEpz82x34IM9/zc8KGxQoXg1liNC/izpRM/MBdt44Nmx41ZWqk+FQ==
22392319

2320+
fast-glob@^3.3.2:
2321+
version "3.3.3"
2322+
resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.3.3.tgz#d06d585ce8dba90a16b0505c543c3ccfb3aeb818"
2323+
integrity sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==
2324+
dependencies:
2325+
"@nodelib/fs.stat" "^2.0.2"
2326+
"@nodelib/fs.walk" "^1.2.3"
2327+
glob-parent "^5.1.2"
2328+
merge2 "^1.3.0"
2329+
micromatch "^4.0.8"
2330+
22402331
fast-json-stable-stringify@^2.0.0, fast-json-stable-stringify@^2.1.0:
22412332
version "2.1.0"
22422333
resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633"
@@ -2257,6 +2348,13 @@ fast-uri@^3.0.1:
22572348
resolved "https://registry.yarnpkg.com/fast-uri/-/fast-uri-3.0.5.tgz#19f5f9691d0dab9b85861a7bb5d98fca961da9cd"
22582349
integrity sha512-5JnBCWpFlMo0a3ciDy/JckMzzv1U9coZrIhedq+HXxxUfDTAiS0LA8OKVao4G9BxmCVck/jtA5r3KAtRWEyD8Q==
22592350

2351+
fastq@^1.6.0:
2352+
version "1.18.0"
2353+
resolved "https://registry.yarnpkg.com/fastq/-/fastq-1.18.0.tgz#d631d7e25faffea81887fe5ea8c9010e1b36fee0"
2354+
integrity sha512-QKHXPW0hD8g4UET03SdOdunzSouc9N4AuHdsX8XNcTsuz+yYFILVNIX4l9yHABMhiEI9Db0JTTIpu0wB+Y1QQw==
2355+
dependencies:
2356+
reusify "^1.0.4"
2357+
22602358
fb-watchman@^2.0.0:
22612359
version "2.0.2"
22622360
resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-2.0.2.tgz#e9524ee6b5c77e9e5001af0f85f3adbb8623255c"
@@ -2475,6 +2573,13 @@ get-symbol-description@^1.1.0:
24752573
es-errors "^1.3.0"
24762574
get-intrinsic "^1.2.6"
24772575

2576+
glob-parent@^5.1.2:
2577+
version "5.1.2"
2578+
resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4"
2579+
integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==
2580+
dependencies:
2581+
is-glob "^4.0.1"
2582+
24782583
glob-parent@^6.0.2:
24792584
version "6.0.2"
24802585
resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-6.0.2.tgz#6d237d99083950c79290f24c7642a3de9a28f9e3"
@@ -2893,7 +2998,7 @@ is-generator-function@^1.0.10:
28932998
has-tostringtag "^1.0.2"
28942999
safe-regex-test "^1.1.0"
28953000

2896-
is-glob@^4.0.0, is-glob@^4.0.3:
3001+
is-glob@^4.0.0, is-glob@^4.0.1, is-glob@^4.0.3:
28973002
version "4.0.3"
28983003
resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.3.tgz#64f61e42cbbb2eec2071a9dac0b28ba1e65d5084"
28993004
integrity sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==
@@ -3783,12 +3888,17 @@ merge-stream@^2.0.0:
37833888
resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60"
37843889
integrity sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==
37853890

3891+
merge2@^1.3.0:
3892+
version "1.4.1"
3893+
resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.4.1.tgz#4368892f885e907455a6fd7dc55c0c9d404990ae"
3894+
integrity sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==
3895+
37863896
merge@^2.1.1:
37873897
version "2.1.1"
37883898
resolved "https://registry.yarnpkg.com/merge/-/merge-2.1.1.tgz#59ef4bf7e0b3e879186436e8481c06a6c162ca98"
37893899
integrity sha512-jz+Cfrg9GWOZbQAnDQ4hlVnQky+341Yk5ru8bZSe6sIDTCIg8n9i/u7hSQGSVOF3C7lH6mGtqjkiT9G4wFLL0w==
37903900

3791-
micromatch@^4.0.2, micromatch@^4.0.4, micromatch@~4.0.8:
3901+
micromatch@^4.0.2, micromatch@^4.0.4, micromatch@^4.0.8, micromatch@~4.0.8:
37923902
version "4.0.8"
37933903
resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.8.tgz#d66fa18f3a47076789320b9b1af32bd86d9fa202"
37943904
integrity sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==
@@ -3828,6 +3938,13 @@ minimatch@^3.0.4, minimatch@^3.1.1, minimatch@^3.1.2:
38283938
dependencies:
38293939
brace-expansion "^1.1.7"
38303940

3941+
minimatch@^9.0.4:
3942+
version "9.0.5"
3943+
resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.5.tgz#d74f9dd6b57d83d8e98cfb82133b03978bc929e5"
3944+
integrity sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==
3945+
dependencies:
3946+
brace-expansion "^2.0.1"
3947+
38313948
minimist@1.2.7:
38323949
version "1.2.7"
38333950
resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.7.tgz#daa1c4d91f507390437c6a8bc01078e7000c4d18"
@@ -4419,6 +4536,11 @@ restore-cursor@^5.0.0:
44194536
onetime "^7.0.0"
44204537
signal-exit "^4.1.0"
44214538

4539+
reusify@^1.0.4:
4540+
version "1.0.4"
4541+
resolved "https://registry.yarnpkg.com/reusify/-/reusify-1.0.4.tgz#90da382b1e126efc02146e90845a88db12925d76"
4542+
integrity sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==
4543+
44224544
rfdc@^1.4.1:
44234545
version "1.4.1"
44244546
resolved "https://registry.yarnpkg.com/rfdc/-/rfdc-1.4.1.tgz#778f76c4fb731d93414e8f925fbecf64cce7f6ca"
@@ -4444,7 +4566,7 @@ run-parallel-limit@^1.1.0:
44444566
dependencies:
44454567
queue-microtask "^1.2.2"
44464568

4447-
run-parallel@^1.1.2, run-parallel@^1.2.0:
4569+
run-parallel@^1.1.2, run-parallel@^1.1.9, run-parallel@^1.2.0:
44484570
version "1.2.0"
44494571
resolved "https://registry.yarnpkg.com/run-parallel/-/run-parallel-1.2.0.tgz#66d1368da7bdf921eb9d95bd1a9229e7f21a43ee"
44504572
integrity sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==
@@ -4511,7 +4633,7 @@ semver@^6.3.0, semver@^6.3.1:
45114633
resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4"
45124634
integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==
45134635

4514-
semver@^7.5.3, semver@^7.5.4:
4636+
semver@^7.5.3, semver@^7.5.4, semver@^7.6.0:
45154637
version "7.6.3"
45164638
resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.3.tgz#980f7b5550bc175fb4dc09403085627f9eb33143"
45174639
integrity sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==
@@ -5006,6 +5128,11 @@ torrent-piece@^2.0.1:
50065128
resolved "https://registry.yarnpkg.com/torrent-piece/-/torrent-piece-2.0.1.tgz#a1a50fffa589d9bf9560e38837230708bc3afdc6"
50075129
integrity sha512-JLSOyvQVLI6JTWqioY4vFL0JkEUKQcaHQsU3loxkCvPTSttw8ePs2tFwsP4XIjw99Fz8EdOzt/4faykcbnPbCQ==
50085130

5131+
ts-api-utils@^2.0.0:
5132+
version "2.0.0"
5133+
resolved "https://registry.yarnpkg.com/ts-api-utils/-/ts-api-utils-2.0.0.tgz#b9d7d5f7ec9f736f4d0f09758b8607979044a900"
5134+
integrity sha512-xCt/TOAc+EOHS1XPnijD3/yzpH6qg2xppZO1YDqGoVsNXfQfzHpOdNuXwrwOU8u4ITXJyDCTyt8w5g1sZv9ynQ==
5135+
50095136
tsconfig-paths@^3.15.0:
50105137
version "3.15.0"
50115138
resolved "https://registry.yarnpkg.com/tsconfig-paths/-/tsconfig-paths-3.15.0.tgz#5299ec605e55b1abb23ec939ef15edaf483070d4"

0 commit comments

Comments
 (0)