Skip to content

Commit e57dec8

Browse files
committed
upgrade @shopify/eslint-plugin 46.0.0
1 parent bd4de2b commit e57dec8

File tree

4 files changed

+103
-40
lines changed

4 files changed

+103
-40
lines changed

.eslintrc.js

-35
This file was deleted.

eslint.config.mjs

+46
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
import tsParser from "@typescript-eslint/parser";
2+
import shopifyPlugin from "@shopify/eslint-plugin";
3+
4+
const isVsCode = Boolean(process.env.VSCODE_CWD);
5+
6+
const developmentOverrides = isVsCode
7+
? {
8+
"no-console": "warn",
9+
"@shopify/no-debugger": "warn",
10+
}
11+
: {};
12+
13+
const config = [
14+
...shopifyPlugin.configs.core,
15+
...shopifyPlugin.configs.typescript,
16+
...shopifyPlugin.configs.prettier,
17+
{
18+
languageOptions: {
19+
parser: tsParser,
20+
ecmaVersion: 5,
21+
sourceType: "script",
22+
23+
parserOptions: {
24+
project: "tsconfig.json",
25+
},
26+
},
27+
28+
settings: {
29+
"import/resolver": {
30+
typescript: {
31+
project: "tsconfig.json",
32+
},
33+
},
34+
},
35+
36+
rules: {
37+
"consistent-return": "off",
38+
"no-warning-comments": "off",
39+
"max-len": ["error", { code: 120 }],
40+
...developmentOverrides,
41+
},
42+
},
43+
44+
];
45+
46+
export default config;

package.json

+3-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,9 @@
5959
},
6060
"devDependencies": {
6161
"@babel/core": "^7.25.2",
62-
"@shopify/eslint-plugin": "^45.0.0",
62+
"@eslint/eslintrc": "^3.1.0",
63+
"@eslint/js": "^9.8.0",
64+
"@shopify/eslint-plugin": "^46.0.0",
6365
"@shopify/prettier-config": "^1.1.2",
6466
"@types/glob": "^8.1.0",
6567
"@types/mocha": "^10.0.7",

yarn.lock

+54-4
Original file line numberDiff line numberDiff line change
@@ -460,11 +460,31 @@
460460
minimatch "^3.1.2"
461461
strip-json-comments "^3.1.1"
462462

463+
"@eslint/eslintrc@^3.1.0":
464+
version "3.1.0"
465+
resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-3.1.0.tgz#dbd3482bfd91efa663cbe7aa1f506839868207b6"
466+
integrity sha512-4Bfj15dVJdoy3RfZmmo86RK1Fwzn6SstsvK9JS+BaVKqC6QQQQyXekNaC+g+LKNgkQ+2VhGAzm6hO40AhMR3zQ==
467+
dependencies:
468+
ajv "^6.12.4"
469+
debug "^4.3.2"
470+
espree "^10.0.1"
471+
globals "^14.0.0"
472+
ignore "^5.2.0"
473+
import-fresh "^3.2.1"
474+
js-yaml "^4.1.0"
475+
minimatch "^3.1.2"
476+
strip-json-comments "^3.1.1"
477+
463478
464479
version "8.57.0"
465480
resolved "https://registry.yarnpkg.com/@eslint/js/-/js-8.57.0.tgz#a5417ae8427873f1dd08b70b3574b453e67b5f7f"
466481
integrity sha512-Ys+3g2TaW7gADOJzPt83SJtCDhMjndcDMFVQ/Tj9iA1BfJzFKD9mAUXT3OenpuPHbI6P/myECxRJrofUsDx/5g==
467482

483+
"@eslint/js@^9.8.0":
484+
version "9.8.0"
485+
resolved "https://registry.yarnpkg.com/@eslint/js/-/js-9.8.0.tgz#ae9bc14bb839713c5056f5018bcefa955556d3a4"
486+
integrity sha512-MfluB7EUfxXtv3i/++oh89uzAr4PDI4nn201hsp+qaXqsjAWzinlZEHEfPgAX4doIlKvPG/i0A9dpKxOLII8yA==
487+
468488
"@humanwhocodes/config-array@^0.11.14":
469489
version "0.11.14"
470490
resolved "https://registry.yarnpkg.com/@humanwhocodes/config-array/-/config-array-0.11.14.tgz#d78e481a039f7566ecc9660b4ea7fe6b1fec442b"
@@ -590,10 +610,10 @@
590610
resolved "https://registry.yarnpkg.com/@pkgr/core/-/core-0.1.1.tgz#1ec17e2edbec25c8306d424ecfbf13c7de1aaa31"
591611
integrity sha512-cq8o4cWH0ibXh9VGi5P20Tu9XF/0fFXl9EUinr9QfTM7a7p0oTA4iJRCQWppXR1Pg8dSM0UCItCkPwsk9qWWYA==
592612

593-
"@shopify/eslint-plugin@^45.0.0":
594-
version "45.0.0"
595-
resolved "https://registry.yarnpkg.com/@shopify/eslint-plugin/-/eslint-plugin-45.0.0.tgz#e4a87e66f89f4a09f1268378bd8caef713661744"
596-
integrity sha512-aRgVkl+EovLk6OC4WzT+C6hgAyta5VReEIdetpe+/bJhVovlqbFjYa3yHGvEM4VuWv8sim7XH2VV3ZsDiwpgvQ==
613+
"@shopify/eslint-plugin@^46.0.0":
614+
version "46.0.0"
615+
resolved "https://registry.yarnpkg.com/@shopify/eslint-plugin/-/eslint-plugin-46.0.0.tgz#1943e4d5064fd33311047358ddeb3bb41856cc71"
616+
integrity sha512-sYUKGaBMXcTEyvMxSECb1H8YPQojgsv6FkUWDN1isLNDrTyk52VETCmRFiS9Aj/hon8W6x8IL5597FyN/SC+qg==
597617
dependencies:
598618
"@babel/eslint-parser" "^7.16.3"
599619
"@babel/eslint-plugin" "^7.14.5"
@@ -615,6 +635,7 @@
615635
eslint-plugin-react "^7.34.1"
616636
eslint-plugin-react-hooks "^4.6.2"
617637
eslint-plugin-sort-class-members "^1.20.0"
638+
globals "^15.8.0"
618639
jsx-ast-utils "^3.2.1"
619640
pkg-dir "^5.0.0"
620641
pluralize "^8.0.0"
@@ -947,6 +968,11 @@ acorn-jsx@^5.3.2:
947968
resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.3.2.tgz#7ed5bb55908b3b2f1bc55c6af1653bada7f07937"
948969
integrity sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==
949970

971+
acorn@^8.12.0:
972+
version "8.12.1"
973+
resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.12.1.tgz#71616bdccbe25e27a54439e0046e89ca76df2248"
974+
integrity sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==
975+
950976
acorn@^8.9.0:
951977
version "8.9.0"
952978
resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.9.0.tgz#78a16e3b2bcc198c10822786fa6679e245db5b59"
@@ -2287,6 +2313,11 @@ eslint-visitor-keys@^3.3.0, eslint-visitor-keys@^3.4.1, eslint-visitor-keys@^3.4
22872313
resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz#0cd72fe8550e3c2eae156a96a4dddcd1c8ac5800"
22882314
integrity sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==
22892315

2316+
eslint-visitor-keys@^4.0.0:
2317+
version "4.0.0"
2318+
resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-4.0.0.tgz#e3adc021aa038a2a8e0b2f8b0ce8f66b9483b1fb"
2319+
integrity sha512-OtIRv/2GyiF6o/d8K7MYKKbXrOUBIK6SfkIRM4Z0dY3w+LiQ0vy3F57m0Z71bjbyeiWFiHJ8brqnmE6H6/jEuw==
2320+
22902321
eslint@^8.57.0:
22912322
version "8.57.0"
22922323
resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.57.0.tgz#c786a6fd0e0b68941aaf624596fb987089195668"
@@ -2331,6 +2362,15 @@ eslint@^8.57.0:
23312362
strip-ansi "^6.0.1"
23322363
text-table "^0.2.0"
23332364

2365+
espree@^10.0.1:
2366+
version "10.1.0"
2367+
resolved "https://registry.yarnpkg.com/espree/-/espree-10.1.0.tgz#8788dae611574c0f070691f522e4116c5a11fc56"
2368+
integrity sha512-M1M6CpiE6ffoigIOWYO9UDP8TMUw9kqb21tf+08IgDYjCsOvCuDt4jQcZmoYxx+w7zlKw9/N0KXfto+I8/FrXA==
2369+
dependencies:
2370+
acorn "^8.12.0"
2371+
acorn-jsx "^5.3.2"
2372+
eslint-visitor-keys "^4.0.0"
2373+
23342374
espree@^9.6.0, espree@^9.6.1:
23352375
version "9.6.1"
23362376
resolved "https://registry.yarnpkg.com/espree/-/espree-9.6.1.tgz#a2a17b8e434690a5432f2f8018ce71d331a48c6f"
@@ -2681,6 +2721,16 @@ globals@^13.19.0:
26812721
dependencies:
26822722
type-fest "^0.20.2"
26832723

2724+
globals@^14.0.0:
2725+
version "14.0.0"
2726+
resolved "https://registry.yarnpkg.com/globals/-/globals-14.0.0.tgz#898d7413c29babcf6bafe56fcadded858ada724e"
2727+
integrity sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==
2728+
2729+
globals@^15.8.0:
2730+
version "15.9.0"
2731+
resolved "https://registry.yarnpkg.com/globals/-/globals-15.9.0.tgz#e9de01771091ffbc37db5714dab484f9f69ff399"
2732+
integrity sha512-SmSKyLLKFbSr6rptvP8izbyxJL4ILwqO9Jg23UA0sDlGlu58V59D1//I3vlc0KJphVdUR7vMjHIplYnzBxorQA==
2733+
26842734
globalthis@^1.0.3:
26852735
version "1.0.3"
26862736
resolved "https://registry.yarnpkg.com/globalthis/-/globalthis-1.0.3.tgz#5852882a52b80dc301b0660273e1ed082f0b6ccf"

0 commit comments

Comments
 (0)