@whoj/eslint-config 2.0.0 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/README.md +1 -1
- package/dist/{chunk-ZBFF7OLB.js → chunk-5NT2OOQW.js} +99 -99
- package/dist/cli.js +9 -9
- package/dist/{dist-BE4MFJS4.js → dist-ZJ2E2ITJ.js} +49 -36
- package/dist/index.d.ts +96 -91
- package/dist/index.js +101 -101
- package/dist/{lib-7QWIUEWR.js → lib-C6BFP32Q.js} +232 -232
- package/dist/{lib-47EDT2ZH.js → lib-XQB7MXK6.js} +1 -1
- package/dist/{sass.node-CCXOXG7K.js → sass.node-L3JPZGSW.js} +2268 -1981
- package/package.json +9 -9
package/dist/cli.js
CHANGED
|
@@ -21,8 +21,8 @@ import c from "picocolors";
|
|
|
21
21
|
var package_default = {
|
|
22
22
|
name: "@whoj/eslint-config",
|
|
23
23
|
type: "module",
|
|
24
|
-
version: "2.
|
|
25
|
-
packageManager: "pnpm@10.2.
|
|
24
|
+
version: "2.1.0",
|
|
25
|
+
packageManager: "pnpm@10.2.1",
|
|
26
26
|
description: "ESLint config",
|
|
27
27
|
license: "MIT",
|
|
28
28
|
homepage: "https://github.com/who-jonson/eslint-config",
|
|
@@ -56,7 +56,7 @@ var package_default = {
|
|
|
56
56
|
peerDependencies: {
|
|
57
57
|
"@prettier/plugin-xml": "^3.4.1",
|
|
58
58
|
"@unocss/eslint-plugin": ">=0.50.0",
|
|
59
|
-
eslint: "^9.
|
|
59
|
+
eslint: "^9.19.0",
|
|
60
60
|
"eslint-plugin-format": ">=0.1.0"
|
|
61
61
|
},
|
|
62
62
|
peerDependenciesMeta: {
|
|
@@ -81,7 +81,7 @@ var package_default = {
|
|
|
81
81
|
"@stylistic/eslint-plugin": "^3.0.1",
|
|
82
82
|
"@typescript-eslint/eslint-plugin": "^8.22.0",
|
|
83
83
|
"@typescript-eslint/parser": "^8.22.0",
|
|
84
|
-
"@vitest/eslint-plugin": "^1.1.
|
|
84
|
+
"@vitest/eslint-plugin": "^1.1.26",
|
|
85
85
|
"eslint-config-flat-gitignore": "^2.0.0",
|
|
86
86
|
"eslint-flat-config-utils": "^2.0.1",
|
|
87
87
|
"eslint-merge-processors": "^1.0.0",
|
|
@@ -112,18 +112,18 @@ var package_default = {
|
|
|
112
112
|
},
|
|
113
113
|
devDependencies: {
|
|
114
114
|
"@antfu/ni": "^23.3.1",
|
|
115
|
-
"@eslint-react/eslint-plugin": "^1.26.
|
|
115
|
+
"@eslint-react/eslint-plugin": "^1.26.2",
|
|
116
116
|
"@eslint/config-inspector": "^1.0.0",
|
|
117
117
|
"@prettier/plugin-xml": "^3.4.1",
|
|
118
118
|
"@stylistic/eslint-plugin-migrate": "^3.0.1",
|
|
119
119
|
"@types/fs-extra": "^11.0.4",
|
|
120
|
-
"@types/node": "^22.13.
|
|
120
|
+
"@types/node": "^22.13.1",
|
|
121
121
|
"@types/prompts": "^2.4.9",
|
|
122
122
|
"@types/yargs": "^17.0.33",
|
|
123
123
|
"@unocss/eslint-plugin": "^65.4.3",
|
|
124
124
|
"@whoj/eslint-config": "workspace:*",
|
|
125
125
|
"astro-eslint-parser": "^1.2.1",
|
|
126
|
-
bumpp: "^10.0.
|
|
126
|
+
bumpp: "^10.0.2",
|
|
127
127
|
eslint: "^9.19.0",
|
|
128
128
|
"eslint-plugin-astro": "^1.3.1",
|
|
129
129
|
"eslint-plugin-format": "^1.0.1",
|
|
@@ -140,9 +140,9 @@ var package_default = {
|
|
|
140
140
|
"prettier-plugin-astro": "^0.14.1",
|
|
141
141
|
"prettier-plugin-slidev": "^1.0.5",
|
|
142
142
|
rimraf: "^6.0.1",
|
|
143
|
-
sass: "^1.
|
|
143
|
+
sass: "^1.84.0",
|
|
144
144
|
"simple-git-hooks": "^2.11.1",
|
|
145
|
-
svelte: "^5.19.
|
|
145
|
+
svelte: "^5.19.9",
|
|
146
146
|
"svelte-eslint-parser": "^0.43.0",
|
|
147
147
|
tsup: "^8.3.6",
|
|
148
148
|
tsx: "^4.19.2",
|
|
@@ -12968,19 +12968,19 @@ var require_dist6 = __commonJS({
|
|
|
12968
12968
|
}
|
|
12969
12969
|
});
|
|
12970
12970
|
|
|
12971
|
-
// node_modules/.pnpm/@eslint-react+eslint-plugin@1.26.
|
|
12971
|
+
// node_modules/.pnpm/@eslint-react+eslint-plugin@1.26.2_eslint@9.19.0_jiti@2.4.2__ts-api-utils@2.0.1_typescript@5.7.3__typescript@5.7.3/node_modules/@eslint-react/eslint-plugin/dist/index.mjs
|
|
12972
12972
|
init_esm_shims();
|
|
12973
12973
|
|
|
12974
|
-
// node_modules/.pnpm/eslint-plugin-react-debug@1.26.
|
|
12974
|
+
// node_modules/.pnpm/eslint-plugin-react-debug@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/eslint-plugin-react-debug/dist/index.mjs
|
|
12975
12975
|
init_esm_shims();
|
|
12976
12976
|
|
|
12977
|
-
// node_modules/.pnpm/@eslint-react+core@1.26.
|
|
12977
|
+
// node_modules/.pnpm/@eslint-react+core@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/@eslint-react/core/dist/index.mjs
|
|
12978
12978
|
init_esm_shims();
|
|
12979
12979
|
|
|
12980
|
-
// node_modules/.pnpm/@eslint-react+ast@1.26.
|
|
12980
|
+
// node_modules/.pnpm/@eslint-react+ast@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/@eslint-react/ast/dist/index.mjs
|
|
12981
12981
|
init_esm_shims();
|
|
12982
12982
|
|
|
12983
|
-
// node_modules/.pnpm/@eslint-react+eff@1.26.
|
|
12983
|
+
// node_modules/.pnpm/@eslint-react+eff@1.26.2/node_modules/@eslint-react/eff/dist/index.mjs
|
|
12984
12984
|
init_esm_shims();
|
|
12985
12985
|
var _ = void 0;
|
|
12986
12986
|
function identity(x2) {
|
|
@@ -13065,7 +13065,7 @@ function getOrUpdate(map, key, callback) {
|
|
|
13065
13065
|
return value;
|
|
13066
13066
|
}
|
|
13067
13067
|
|
|
13068
|
-
// node_modules/.pnpm/@eslint-react+ast@1.26.
|
|
13068
|
+
// node_modules/.pnpm/@eslint-react+ast@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/@eslint-react/ast/dist/index.mjs
|
|
13069
13069
|
var import_types = __toESM(require_dist(), 1);
|
|
13070
13070
|
var import_utils = __toESM(require_dist4(), 1);
|
|
13071
13071
|
var import_typescript_estree = __toESM(require_dist5(), 1);
|
|
@@ -13414,7 +13414,7 @@ function snakeCase(str) {
|
|
|
13414
13414
|
return toLowerCase(delimiterCase(removeApostrophe(str), "_"));
|
|
13415
13415
|
}
|
|
13416
13416
|
|
|
13417
|
-
// node_modules/.pnpm/@eslint-react+ast@1.26.
|
|
13417
|
+
// node_modules/.pnpm/@eslint-react+ast@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/@eslint-react/ast/dist/index.mjs
|
|
13418
13418
|
function findParentNode(node, test) {
|
|
13419
13419
|
if (node == null) return _;
|
|
13420
13420
|
let parent = node.parent;
|
|
@@ -13990,11 +13990,11 @@ function unwrapTypeExpression(node) {
|
|
|
13990
13990
|
return node;
|
|
13991
13991
|
}
|
|
13992
13992
|
|
|
13993
|
-
// node_modules/.pnpm/@eslint-react+jsx@1.26.
|
|
13993
|
+
// node_modules/.pnpm/@eslint-react+jsx@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/@eslint-react/jsx/dist/index.mjs
|
|
13994
13994
|
init_esm_shims();
|
|
13995
13995
|
var import_types3 = __toESM(require_dist(), 1);
|
|
13996
13996
|
|
|
13997
|
-
// node_modules/.pnpm/@eslint-react+var@1.26.
|
|
13997
|
+
// node_modules/.pnpm/@eslint-react+var@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/@eslint-react/var/dist/index.mjs
|
|
13998
13998
|
init_esm_shims();
|
|
13999
13999
|
var import_types2 = __toESM(require_dist(), 1);
|
|
14000
14000
|
var ASTUtils2 = __toESM(require_ast_utils(), 1);
|
|
@@ -14268,7 +14268,7 @@ function getValueConstruction(node, initialScope, hint = ValueConstructionHint.N
|
|
|
14268
14268
|
}
|
|
14269
14269
|
}
|
|
14270
14270
|
|
|
14271
|
-
// node_modules/.pnpm/@eslint-react+jsx@1.26.
|
|
14271
|
+
// node_modules/.pnpm/@eslint-react+jsx@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/@eslint-react/jsx/dist/index.mjs
|
|
14272
14272
|
function findParentAttribute(node, test = constTrue) {
|
|
14273
14273
|
const guard = (node2) => {
|
|
14274
14274
|
return node2.type === import_types3.AST_NODE_TYPES.JSXAttribute && test(node2);
|
|
@@ -14496,7 +14496,7 @@ function isPaddingSpaces(node) {
|
|
|
14496
14496
|
return isLiteral(node) && isWhiteSpace(node) && node.raw.includes("\n");
|
|
14497
14497
|
}
|
|
14498
14498
|
|
|
14499
|
-
// node_modules/.pnpm/@eslint-react+shared@1.26.
|
|
14499
|
+
// node_modules/.pnpm/@eslint-react+shared@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/@eslint-react/shared/dist/index.mjs
|
|
14500
14500
|
init_esm_shims();
|
|
14501
14501
|
var import_utils2 = __toESM(require_dist4(), 1);
|
|
14502
14502
|
import module from "node:module";
|
|
@@ -14622,6 +14622,16 @@ var ValiError = class extends Error {
|
|
|
14622
14622
|
}
|
|
14623
14623
|
};
|
|
14624
14624
|
// @__NO_SIDE_EFFECTS__
|
|
14625
|
+
function getFallback(schema4, dataset, config2) {
|
|
14626
|
+
return typeof schema4.fallback === "function" ? (
|
|
14627
|
+
// @ts-expect-error
|
|
14628
|
+
schema4.fallback(dataset, config2)
|
|
14629
|
+
) : (
|
|
14630
|
+
// @ts-expect-error
|
|
14631
|
+
schema4.fallback
|
|
14632
|
+
);
|
|
14633
|
+
}
|
|
14634
|
+
// @__NO_SIDE_EFFECTS__
|
|
14625
14635
|
function getDefault(schema4, dataset, config2) {
|
|
14626
14636
|
return typeof schema4.default === "function" ? (
|
|
14627
14637
|
// @ts-expect-error
|
|
@@ -14765,6 +14775,8 @@ function object(entries, message) {
|
|
|
14765
14775
|
dataset.typed = false;
|
|
14766
14776
|
}
|
|
14767
14777
|
dataset.value[key] = valueDataset.value;
|
|
14778
|
+
} else if (valueSchema.fallback !== void 0) {
|
|
14779
|
+
dataset.value[key] = /* @__PURE__ */ getFallback(valueSchema);
|
|
14768
14780
|
} else if (valueSchema.type !== "exact_optional" && valueSchema.type !== "optional" && valueSchema.type !== "nullish") {
|
|
14769
14781
|
_addIssue(this, "key", dataset, config2, {
|
|
14770
14782
|
input: void 0,
|
|
@@ -15736,7 +15748,7 @@ function getSettingsFromContext(context) {
|
|
|
15736
15748
|
return toNormalizedSettings(decodeSettings(context.settings));
|
|
15737
15749
|
}
|
|
15738
15750
|
|
|
15739
|
-
// node_modules/.pnpm/@eslint-react+core@1.26.
|
|
15751
|
+
// node_modules/.pnpm/@eslint-react+core@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/@eslint-react/core/dist/index.mjs
|
|
15740
15752
|
var import_types4 = __toESM(require_dist(), 1);
|
|
15741
15753
|
|
|
15742
15754
|
// node_modules/.pnpm/birecord@0.1.1/node_modules/birecord/dist/mod.mjs
|
|
@@ -15762,7 +15774,7 @@ function reverse(record) {
|
|
|
15762
15774
|
);
|
|
15763
15775
|
}
|
|
15764
15776
|
|
|
15765
|
-
// node_modules/.pnpm/@eslint-react+core@1.26.
|
|
15777
|
+
// node_modules/.pnpm/@eslint-react+core@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/@eslint-react/core/dist/index.mjs
|
|
15766
15778
|
function isInitializedFromReact(name14, importSource, initialScope) {
|
|
15767
15779
|
return name14.toLowerCase() === "react" || isInitializedFromSource(
|
|
15768
15780
|
name14,
|
|
@@ -16360,10 +16372,10 @@ function isFunctionOfUseEffectCleanup(node) {
|
|
|
16360
16372
|
return nearFunction === nearFunctionOfReturn && isFunctionOfUseEffectSetup(nearFunction);
|
|
16361
16373
|
}
|
|
16362
16374
|
|
|
16363
|
-
// node_modules/.pnpm/eslint-plugin-react-debug@1.26.
|
|
16375
|
+
// node_modules/.pnpm/eslint-plugin-react-debug@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/eslint-plugin-react-debug/dist/index.mjs
|
|
16364
16376
|
var import_utils3 = __toESM(require_dist4(), 1);
|
|
16365
16377
|
var name = "eslint-plugin-react-debug";
|
|
16366
|
-
var version = "1.26.
|
|
16378
|
+
var version = "1.26.2";
|
|
16367
16379
|
var createRule = createRuleForPlugin("debug");
|
|
16368
16380
|
var RULE_NAME = "class-component";
|
|
16369
16381
|
var RULE_FEATURES = [
|
|
@@ -16561,7 +16573,7 @@ var index_default = {
|
|
|
16561
16573
|
}
|
|
16562
16574
|
};
|
|
16563
16575
|
|
|
16564
|
-
// node_modules/.pnpm/eslint-plugin-react-dom@1.26.
|
|
16576
|
+
// node_modules/.pnpm/eslint-plugin-react-dom@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/eslint-plugin-react-dom/dist/index.mjs
|
|
16565
16577
|
init_esm_shims();
|
|
16566
16578
|
var import_types5 = __toESM(require_dist(), 1);
|
|
16567
16579
|
|
|
@@ -16654,9 +16666,9 @@ var assertValidOperator = (op) => {
|
|
|
16654
16666
|
}
|
|
16655
16667
|
};
|
|
16656
16668
|
|
|
16657
|
-
// node_modules/.pnpm/eslint-plugin-react-dom@1.26.
|
|
16669
|
+
// node_modules/.pnpm/eslint-plugin-react-dom@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/eslint-plugin-react-dom/dist/index.mjs
|
|
16658
16670
|
var name2 = "eslint-plugin-react-dom";
|
|
16659
|
-
var version2 = "1.26.
|
|
16671
|
+
var version2 = "1.26.2";
|
|
16660
16672
|
var createRule2 = createRuleForPlugin("dom");
|
|
16661
16673
|
function findCustomComponent(name23, components) {
|
|
16662
16674
|
return components.findLast((c2) => c2.name === name23 || c2.re.test(name23));
|
|
@@ -18360,11 +18372,11 @@ var index_default2 = {
|
|
|
18360
18372
|
}
|
|
18361
18373
|
};
|
|
18362
18374
|
|
|
18363
|
-
// node_modules/.pnpm/eslint-plugin-react-hooks-extra@1.26.
|
|
18375
|
+
// node_modules/.pnpm/eslint-plugin-react-hooks-extra@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/eslint-plugin-react-hooks-extra/dist/index.mjs
|
|
18364
18376
|
init_esm_shims();
|
|
18365
18377
|
var import_types6 = __toESM(require_dist(), 1);
|
|
18366
18378
|
var name3 = "eslint-plugin-react-hooks-extra";
|
|
18367
|
-
var version3 = "1.26.
|
|
18379
|
+
var version3 = "1.26.2";
|
|
18368
18380
|
var createRule3 = createRuleForPlugin("hooks-extra");
|
|
18369
18381
|
function isFromHookCall(name23, context, settings4, predicate = constTrue) {
|
|
18370
18382
|
const hookAlias = settings4.additionalHooks[name23] ?? [];
|
|
@@ -19145,12 +19157,12 @@ var index_default3 = {
|
|
|
19145
19157
|
}
|
|
19146
19158
|
};
|
|
19147
19159
|
|
|
19148
|
-
// node_modules/.pnpm/eslint-plugin-react-naming-convention@1.26.
|
|
19160
|
+
// node_modules/.pnpm/eslint-plugin-react-naming-convention@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/eslint-plugin-react-naming-convention/dist/index.mjs
|
|
19149
19161
|
init_esm_shims();
|
|
19150
19162
|
import path from "node:path";
|
|
19151
19163
|
var import_types7 = __toESM(require_dist(), 1);
|
|
19152
19164
|
var name4 = "eslint-plugin-react-naming-convention";
|
|
19153
|
-
var version4 = "1.26.
|
|
19165
|
+
var version4 = "1.26.2";
|
|
19154
19166
|
var createRule4 = createRuleForPlugin("naming-convention");
|
|
19155
19167
|
var RULE_NAME14 = "component-name";
|
|
19156
19168
|
var defaultOptions = [
|
|
@@ -19565,12 +19577,12 @@ var index_default4 = {
|
|
|
19565
19577
|
}
|
|
19566
19578
|
};
|
|
19567
19579
|
|
|
19568
|
-
// node_modules/.pnpm/eslint-plugin-react-web-api@1.26.
|
|
19580
|
+
// node_modules/.pnpm/eslint-plugin-react-web-api@1.26.2_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/eslint-plugin-react-web-api/dist/index.mjs
|
|
19569
19581
|
init_esm_shims();
|
|
19570
19582
|
var import_utils5 = __toESM(require_dist4(), 1);
|
|
19571
19583
|
var import_types8 = __toESM(require_dist(), 1);
|
|
19572
19584
|
var name5 = "eslint-plugin-react-web-api";
|
|
19573
|
-
var version5 = "1.26.
|
|
19585
|
+
var version5 = "1.26.2";
|
|
19574
19586
|
var createRule5 = createRuleForPlugin("web-api");
|
|
19575
19587
|
function getInstanceID(node, prev) {
|
|
19576
19588
|
switch (true) {
|
|
@@ -20250,7 +20262,7 @@ var index_default5 = {
|
|
|
20250
20262
|
}
|
|
20251
20263
|
};
|
|
20252
20264
|
|
|
20253
|
-
// node_modules/.pnpm/eslint-plugin-react-x@1.26.
|
|
20265
|
+
// node_modules/.pnpm/eslint-plugin-react-x@1.26.2_eslint@9.19.0_jiti@2.4.2__ts-api-utils@2.0.1_typescript@5.7.3__typescript@5.7.3/node_modules/eslint-plugin-react-x/dist/index.mjs
|
|
20254
20266
|
init_esm_shims();
|
|
20255
20267
|
var import_types9 = __toESM(require_dist(), 1);
|
|
20256
20268
|
var import_type_utils2 = __toESM(require_dist6(), 1);
|
|
@@ -20504,7 +20516,7 @@ function isReadonlyPropertyIntersection(type, name14, typeChecker) {
|
|
|
20504
20516
|
});
|
|
20505
20517
|
}
|
|
20506
20518
|
|
|
20507
|
-
// node_modules/.pnpm/eslint-plugin-react-x@1.26.
|
|
20519
|
+
// node_modules/.pnpm/eslint-plugin-react-x@1.26.2_eslint@9.19.0_jiti@2.4.2__ts-api-utils@2.0.1_typescript@5.7.3__typescript@5.7.3/node_modules/eslint-plugin-react-x/dist/index.mjs
|
|
20508
20520
|
var import_typescript4 = __toESM(require_typescript(), 1);
|
|
20509
20521
|
|
|
20510
20522
|
// node_modules/.pnpm/is-immutable-type@5.0.1_eslint@9.19.0_jiti@2.4.2__typescript@5.7.3/node_modules/is-immutable-type/dist/index.mjs
|
|
@@ -22458,9 +22470,9 @@ function createIndexSignatureTaskStates(parameters, m_state, kind, typeData) {
|
|
|
22458
22470
|
return [];
|
|
22459
22471
|
}
|
|
22460
22472
|
|
|
22461
|
-
// node_modules/.pnpm/eslint-plugin-react-x@1.26.
|
|
22473
|
+
// node_modules/.pnpm/eslint-plugin-react-x@1.26.2_eslint@9.19.0_jiti@2.4.2__ts-api-utils@2.0.1_typescript@5.7.3__typescript@5.7.3/node_modules/eslint-plugin-react-x/dist/index.mjs
|
|
22462
22474
|
var name6 = "eslint-plugin-react-x";
|
|
22463
|
-
var version6 = "1.26.
|
|
22475
|
+
var version6 = "1.26.2";
|
|
22464
22476
|
var createRule6 = createRuleForPlugin("x");
|
|
22465
22477
|
function getAssociatedTokens(context, node) {
|
|
22466
22478
|
{
|
|
@@ -23424,7 +23436,7 @@ var no_context_provider_default = createRule6({
|
|
|
23424
23436
|
},
|
|
23425
23437
|
fixable: "code",
|
|
23426
23438
|
messages: {
|
|
23427
|
-
noContextProvider: "In React 19, you can render '<
|
|
23439
|
+
noContextProvider: "In React 19, you can render '<{{contextName}}>' as a provider instead of '<{{contextName}}.Provider>'."
|
|
23428
23440
|
},
|
|
23429
23441
|
schema: []
|
|
23430
23442
|
},
|
|
@@ -23437,15 +23449,16 @@ var no_context_provider_default = createRule6({
|
|
|
23437
23449
|
}
|
|
23438
23450
|
return {
|
|
23439
23451
|
JSXElement(node) {
|
|
23440
|
-
const
|
|
23441
|
-
if (
|
|
23442
|
-
|
|
23443
|
-
}
|
|
23452
|
+
const [name23, ...rest] = getElementName(node).split(".").reverse();
|
|
23453
|
+
if (name23 !== "Provider") return;
|
|
23454
|
+
const contextName = rest.reverse().join(".");
|
|
23444
23455
|
context.report({
|
|
23445
23456
|
messageId: "noContextProvider",
|
|
23446
23457
|
node,
|
|
23458
|
+
data: {
|
|
23459
|
+
contextName
|
|
23460
|
+
},
|
|
23447
23461
|
fix(fixer) {
|
|
23448
|
-
const contextName = elementName.replace(/\.Provider$/, "");
|
|
23449
23462
|
const openingElement = node.openingElement;
|
|
23450
23463
|
const closingElement = node.closingElement;
|
|
23451
23464
|
if (closingElement == null) {
|
|
@@ -25810,14 +25823,14 @@ var index_default6 = {
|
|
|
25810
25823
|
}
|
|
25811
25824
|
};
|
|
25812
25825
|
|
|
25813
|
-
// node_modules/.pnpm/@eslint-react+eslint-plugin@1.26.
|
|
25826
|
+
// node_modules/.pnpm/@eslint-react+eslint-plugin@1.26.2_eslint@9.19.0_jiti@2.4.2__ts-api-utils@2.0.1_typescript@5.7.3__typescript@5.7.3/node_modules/@eslint-react/eslint-plugin/dist/index.mjs
|
|
25814
25827
|
var __defProp = Object.defineProperty;
|
|
25815
25828
|
var __export = (target, all) => {
|
|
25816
25829
|
for (var name14 in all)
|
|
25817
25830
|
__defProp(target, name14, { get: all[name14], enumerable: true });
|
|
25818
25831
|
};
|
|
25819
25832
|
var name7 = "@eslint-react/eslint-plugin";
|
|
25820
|
-
var version7 = "1.26.
|
|
25833
|
+
var version7 = "1.26.2";
|
|
25821
25834
|
var all_exports = {};
|
|
25822
25835
|
__export(all_exports, {
|
|
25823
25836
|
name: () => name42,
|
package/dist/index.d.ts
CHANGED
|
@@ -15,61 +15,6 @@ interface RuleOptions {
|
|
|
15
15
|
* @see https://eslint.org/docs/latest/rules/accessor-pairs
|
|
16
16
|
*/
|
|
17
17
|
'accessor-pairs'?: Linter.RuleEntry<AccessorPairs>
|
|
18
|
-
/**
|
|
19
|
-
* Having line breaks styles to object, array and named imports
|
|
20
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/consistent-chaining.md
|
|
21
|
-
*/
|
|
22
|
-
'antfu/consistent-chaining'?: Linter.RuleEntry<AntfuConsistentChaining>
|
|
23
|
-
/**
|
|
24
|
-
* Having line breaks styles to object, array and named imports
|
|
25
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/consistent-list-newline.md
|
|
26
|
-
*/
|
|
27
|
-
'antfu/consistent-list-newline'?: Linter.RuleEntry<AntfuConsistentListNewline>
|
|
28
|
-
/**
|
|
29
|
-
* Enforce Anthony's style of curly bracket
|
|
30
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/curly.md
|
|
31
|
-
*/
|
|
32
|
-
'antfu/curly'?: Linter.RuleEntry<[]>
|
|
33
|
-
/**
|
|
34
|
-
* Newline after if
|
|
35
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/if-newline.md
|
|
36
|
-
*/
|
|
37
|
-
'antfu/if-newline'?: Linter.RuleEntry<[]>
|
|
38
|
-
/**
|
|
39
|
-
* Fix duplication in imports
|
|
40
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/import-dedupe.md
|
|
41
|
-
*/
|
|
42
|
-
'antfu/import-dedupe'?: Linter.RuleEntry<[]>
|
|
43
|
-
/**
|
|
44
|
-
* Enforce consistent indentation in `unindent` template tag
|
|
45
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/indent-unindent.md
|
|
46
|
-
*/
|
|
47
|
-
'antfu/indent-unindent'?: Linter.RuleEntry<AntfuIndentUnindent>
|
|
48
|
-
/**
|
|
49
|
-
* Prevent importing modules in `dist` folder
|
|
50
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-import-dist.test.ts
|
|
51
|
-
*/
|
|
52
|
-
'antfu/no-import-dist'?: Linter.RuleEntry<[]>
|
|
53
|
-
/**
|
|
54
|
-
* Prevent importing modules in `node_modules` folder by relative or absolute path
|
|
55
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-import-node-modules-by-path.test.ts
|
|
56
|
-
*/
|
|
57
|
-
'antfu/no-import-node-modules-by-path'?: Linter.RuleEntry<[]>
|
|
58
|
-
/**
|
|
59
|
-
* Prevent using top-level await
|
|
60
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-top-level-await.test.ts
|
|
61
|
-
*/
|
|
62
|
-
'antfu/no-top-level-await'?: Linter.RuleEntry<[]>
|
|
63
|
-
/**
|
|
64
|
-
* Do not use `exports =`
|
|
65
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-ts-export-equal.test.ts
|
|
66
|
-
*/
|
|
67
|
-
'antfu/no-ts-export-equal'?: Linter.RuleEntry<[]>
|
|
68
|
-
/**
|
|
69
|
-
* Enforce top-level functions to be declared with function keyword
|
|
70
|
-
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/top-level-function.md
|
|
71
|
-
*/
|
|
72
|
-
'antfu/top-level-function'?: Linter.RuleEntry<[]>
|
|
73
18
|
/**
|
|
74
19
|
* Enforce linebreaks after opening and before closing array brackets
|
|
75
20
|
* @see https://eslint.org/docs/latest/rules/array-bracket-newline
|
|
@@ -4934,6 +4879,11 @@ interface RuleOptions {
|
|
|
4934
4879
|
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/prefer-spy-on.md
|
|
4935
4880
|
*/
|
|
4936
4881
|
'test/prefer-spy-on'?: Linter.RuleEntry<[]>
|
|
4882
|
+
/**
|
|
4883
|
+
* enforce using `toBe(true)` and `toBe(false)` over matchers that coerce types to boolean
|
|
4884
|
+
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/prefer-strict-boolean-matchers.md
|
|
4885
|
+
*/
|
|
4886
|
+
'test/prefer-strict-boolean-matchers'?: Linter.RuleEntry<[]>
|
|
4937
4887
|
/**
|
|
4938
4888
|
* enforce strict equal over equal
|
|
4939
4889
|
* @see https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/prefer-strict-equal.md
|
|
@@ -7782,6 +7732,61 @@ interface RuleOptions {
|
|
|
7782
7732
|
* @see https://eslint.vuejs.org/rules/valid-v-text.html
|
|
7783
7733
|
*/
|
|
7784
7734
|
'vue/valid-v-text'?: Linter.RuleEntry<[]>
|
|
7735
|
+
/**
|
|
7736
|
+
* Having line breaks styles to object, array and named imports
|
|
7737
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/consistent-chaining.md
|
|
7738
|
+
*/
|
|
7739
|
+
'whoj/consistent-chaining'?: Linter.RuleEntry<WhojConsistentChaining>
|
|
7740
|
+
/**
|
|
7741
|
+
* Having line breaks styles to object, array and named imports
|
|
7742
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/consistent-list-newline.md
|
|
7743
|
+
*/
|
|
7744
|
+
'whoj/consistent-list-newline'?: Linter.RuleEntry<WhojConsistentListNewline>
|
|
7745
|
+
/**
|
|
7746
|
+
* Enforce Anthony's style of curly bracket
|
|
7747
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/curly.md
|
|
7748
|
+
*/
|
|
7749
|
+
'whoj/curly'?: Linter.RuleEntry<[]>
|
|
7750
|
+
/**
|
|
7751
|
+
* Newline after if
|
|
7752
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/if-newline.md
|
|
7753
|
+
*/
|
|
7754
|
+
'whoj/if-newline'?: Linter.RuleEntry<[]>
|
|
7755
|
+
/**
|
|
7756
|
+
* Fix duplication in imports
|
|
7757
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/import-dedupe.md
|
|
7758
|
+
*/
|
|
7759
|
+
'whoj/import-dedupe'?: Linter.RuleEntry<[]>
|
|
7760
|
+
/**
|
|
7761
|
+
* Enforce consistent indentation in `unindent` template tag
|
|
7762
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/indent-unindent.md
|
|
7763
|
+
*/
|
|
7764
|
+
'whoj/indent-unindent'?: Linter.RuleEntry<WhojIndentUnindent>
|
|
7765
|
+
/**
|
|
7766
|
+
* Prevent importing modules in `dist` folder
|
|
7767
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-import-dist.test.ts
|
|
7768
|
+
*/
|
|
7769
|
+
'whoj/no-import-dist'?: Linter.RuleEntry<[]>
|
|
7770
|
+
/**
|
|
7771
|
+
* Prevent importing modules in `node_modules` folder by relative or absolute path
|
|
7772
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-import-node-modules-by-path.test.ts
|
|
7773
|
+
*/
|
|
7774
|
+
'whoj/no-import-node-modules-by-path'?: Linter.RuleEntry<[]>
|
|
7775
|
+
/**
|
|
7776
|
+
* Prevent using top-level await
|
|
7777
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-top-level-await.test.ts
|
|
7778
|
+
*/
|
|
7779
|
+
'whoj/no-top-level-await'?: Linter.RuleEntry<[]>
|
|
7780
|
+
/**
|
|
7781
|
+
* Do not use `exports =`
|
|
7782
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-ts-export-equal.test.ts
|
|
7783
|
+
*/
|
|
7784
|
+
'whoj/no-ts-export-equal'?: Linter.RuleEntry<[]>
|
|
7785
|
+
/**
|
|
7786
|
+
* Enforce top-level functions to be declared with function keyword
|
|
7787
|
+
* @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/top-level-function.md
|
|
7788
|
+
*/
|
|
7789
|
+
'whoj/top-level-function'?: Linter.RuleEntry<[]>
|
|
7785
7790
|
/**
|
|
7786
7791
|
* Require parentheses around immediate `function` invocations
|
|
7787
7792
|
* @see https://eslint.org/docs/latest/rules/wrap-iife
|
|
@@ -7954,39 +7959,6 @@ type AccessorPairs = []|[{
|
|
|
7954
7959
|
setWithoutGet?: boolean
|
|
7955
7960
|
enforceForClassMembers?: boolean
|
|
7956
7961
|
}]
|
|
7957
|
-
// ----- antfu/consistent-chaining -----
|
|
7958
|
-
type AntfuConsistentChaining = []|[{
|
|
7959
|
-
|
|
7960
|
-
allowLeadingPropertyAccess?: boolean
|
|
7961
|
-
}]
|
|
7962
|
-
// ----- antfu/consistent-list-newline -----
|
|
7963
|
-
type AntfuConsistentListNewline = []|[{
|
|
7964
|
-
ArrayExpression?: boolean
|
|
7965
|
-
ArrayPattern?: boolean
|
|
7966
|
-
ArrowFunctionExpression?: boolean
|
|
7967
|
-
CallExpression?: boolean
|
|
7968
|
-
ExportNamedDeclaration?: boolean
|
|
7969
|
-
FunctionDeclaration?: boolean
|
|
7970
|
-
FunctionExpression?: boolean
|
|
7971
|
-
ImportDeclaration?: boolean
|
|
7972
|
-
JSONArrayExpression?: boolean
|
|
7973
|
-
JSONObjectExpression?: boolean
|
|
7974
|
-
JSXOpeningElement?: boolean
|
|
7975
|
-
NewExpression?: boolean
|
|
7976
|
-
ObjectExpression?: boolean
|
|
7977
|
-
ObjectPattern?: boolean
|
|
7978
|
-
TSFunctionType?: boolean
|
|
7979
|
-
TSInterfaceDeclaration?: boolean
|
|
7980
|
-
TSTupleType?: boolean
|
|
7981
|
-
TSTypeLiteral?: boolean
|
|
7982
|
-
TSTypeParameterDeclaration?: boolean
|
|
7983
|
-
TSTypeParameterInstantiation?: boolean
|
|
7984
|
-
}]
|
|
7985
|
-
// ----- antfu/indent-unindent -----
|
|
7986
|
-
type AntfuIndentUnindent = []|[{
|
|
7987
|
-
indent?: number
|
|
7988
|
-
tags?: string[]
|
|
7989
|
-
}]
|
|
7990
7962
|
// ----- array-bracket-newline -----
|
|
7991
7963
|
type ArrayBracketNewline = []|[(("always" | "never" | "consistent") | {
|
|
7992
7964
|
multiline?: boolean
|
|
@@ -16030,6 +16002,39 @@ type VueValidVOn = []|[{
|
|
|
16030
16002
|
type VueValidVSlot = []|[{
|
|
16031
16003
|
allowModifiers?: boolean
|
|
16032
16004
|
}]
|
|
16005
|
+
// ----- whoj/consistent-chaining -----
|
|
16006
|
+
type WhojConsistentChaining = []|[{
|
|
16007
|
+
|
|
16008
|
+
allowLeadingPropertyAccess?: boolean
|
|
16009
|
+
}]
|
|
16010
|
+
// ----- whoj/consistent-list-newline -----
|
|
16011
|
+
type WhojConsistentListNewline = []|[{
|
|
16012
|
+
ArrayExpression?: boolean
|
|
16013
|
+
ArrayPattern?: boolean
|
|
16014
|
+
ArrowFunctionExpression?: boolean
|
|
16015
|
+
CallExpression?: boolean
|
|
16016
|
+
ExportNamedDeclaration?: boolean
|
|
16017
|
+
FunctionDeclaration?: boolean
|
|
16018
|
+
FunctionExpression?: boolean
|
|
16019
|
+
ImportDeclaration?: boolean
|
|
16020
|
+
JSONArrayExpression?: boolean
|
|
16021
|
+
JSONObjectExpression?: boolean
|
|
16022
|
+
JSXOpeningElement?: boolean
|
|
16023
|
+
NewExpression?: boolean
|
|
16024
|
+
ObjectExpression?: boolean
|
|
16025
|
+
ObjectPattern?: boolean
|
|
16026
|
+
TSFunctionType?: boolean
|
|
16027
|
+
TSInterfaceDeclaration?: boolean
|
|
16028
|
+
TSTupleType?: boolean
|
|
16029
|
+
TSTypeLiteral?: boolean
|
|
16030
|
+
TSTypeParameterDeclaration?: boolean
|
|
16031
|
+
TSTypeParameterInstantiation?: boolean
|
|
16032
|
+
}]
|
|
16033
|
+
// ----- whoj/indent-unindent -----
|
|
16034
|
+
type WhojIndentUnindent = []|[{
|
|
16035
|
+
indent?: number
|
|
16036
|
+
tags?: string[]
|
|
16037
|
+
}]
|
|
16033
16038
|
// ----- wrap-iife -----
|
|
16034
16039
|
type WrapIife = []|[("outside" | "inside" | "any")]|[("outside" | "inside" | "any"), {
|
|
16035
16040
|
functionPrototypeMethods?: boolean
|
|
@@ -16252,7 +16257,7 @@ type Yoda = []|[("always" | "never")]|[("always" | "never"), {
|
|
|
16252
16257
|
onlyEquality?: boolean
|
|
16253
16258
|
}]
|
|
16254
16259
|
// Names of all the configs
|
|
16255
|
-
type ConfigNames = '
|
|
16260
|
+
type ConfigNames = 'whoj/astro/setup' | 'whoj/astro/rules' | 'whoj/eslint-comments/rules' | 'whoj/formatter/setup' | 'whoj/imports/rules' | 'whoj/javascript/setup' | 'whoj/javascript/rules' | 'whoj/jsx/setup' | 'whoj/jsdoc/rules' | 'whoj/jsonc/setup' | 'whoj/jsonc/rules' | 'whoj/markdown/setup' | 'whoj/markdown/processor' | 'whoj/markdown/parser' | 'whoj/markdown/disables' | 'whoj/node/rules' | 'whoj/perfectionist/setup' | 'whoj/react/setup' | 'whoj/react/rules' | 'whoj/solid/setup' | 'whoj/solid/rules' | 'whoj/sort/package-json' | 'whoj/stylistic/rules' | 'whoj/svelte/setup' | 'whoj/svelte/rules' | 'whoj/test/setup' | 'whoj/test/rules' | 'whoj/toml/setup' | 'whoj/toml/rules' | 'whoj/regexp/rules' | 'whoj/typescript/setup' | 'whoj/typescript/parser' | 'whoj/typescript/rules' | 'whoj/unicorn/rules' | 'whoj/unocss' | 'whoj/vue/setup' | 'whoj/vue/rules' | 'whoj/yaml/setup' | 'whoj/yaml/rules'
|
|
16256
16261
|
|
|
16257
16262
|
/**
|
|
16258
16263
|
* Vendor types from Prettier so we don't rely on the dependency.
|
|
@@ -16766,7 +16771,7 @@ declare const defaultPluginRenaming: {
|
|
|
16766
16771
|
* @returns {Promise<TypedFlatConfigItem[]>}
|
|
16767
16772
|
* The merged ESLint configurations.
|
|
16768
16773
|
*/
|
|
16769
|
-
declare function
|
|
16774
|
+
declare function whoj(options?: OptionsConfig & Omit<TypedFlatConfigItem, 'files'>, ...userConfigs: Awaitable<TypedFlatConfigItem | TypedFlatConfigItem[] | FlatConfigComposer<any, any> | Linter.Config[]>[]): FlatConfigComposer<TypedFlatConfigItem, ConfigNames>;
|
|
16770
16775
|
type ResolvedOptions<T> = T extends boolean ? never : NonNullable<T>;
|
|
16771
16776
|
declare function resolveSubOptions<K extends keyof OptionsConfig>(options: OptionsConfig, key: K): ResolvedOptions<OptionsConfig[K]>;
|
|
16772
16777
|
declare function getOverrides<K extends keyof OptionsConfig>(options: OptionsConfig, key: K): Partial<Linter.RulesRecord & RuleOptions>;
|
|
@@ -16948,4 +16953,4 @@ declare function ensurePackages(packages: (string | undefined)[]): Promise<void>
|
|
|
16948
16953
|
declare function isInEditorEnv(): boolean;
|
|
16949
16954
|
declare function isInGitHooksOrLintStaged(): boolean;
|
|
16950
16955
|
|
|
16951
|
-
export { type Awaitable, type ConfigNames, GLOB_ALL_SRC, GLOB_ASTRO, GLOB_ASTRO_TS, GLOB_CSS, GLOB_EXCLUDE, GLOB_GRAPHQL, GLOB_HTML, GLOB_JS, GLOB_JSON, GLOB_JSON5, GLOB_JSONC, GLOB_JSX, GLOB_LESS, GLOB_MARKDOWN, GLOB_MARKDOWN_CODE, GLOB_MARKDOWN_IN_MARKDOWN, GLOB_POSTCSS, GLOB_SCSS, GLOB_SRC, GLOB_SRC_EXT, GLOB_STYLE, GLOB_SVELTE, GLOB_SVG, GLOB_TESTS, GLOB_TOML, GLOB_TS, GLOB_TSX, GLOB_VUE, GLOB_XML, GLOB_YAML, type OptionsComponentExts, type OptionsConfig, type OptionsFiles, type OptionsFormatters, type OptionsHasTypeScript, type OptionsIsInEditor, type OptionsOverrides, type OptionsProjectType, type OptionsRegExp, type OptionsStylistic, type OptionsTypeScriptParserOptions, type OptionsTypeScriptWithTypes, type OptionsTypescript, type OptionsUnicorn, type OptionsUnoCSS, type OptionsVue, type ResolvedOptions, type Rules, type StylisticConfig, StylisticConfigDefaults, type StylisticOptions, type TypedFlatConfigItem,
|
|
16956
|
+
export { type Awaitable, type ConfigNames, GLOB_ALL_SRC, GLOB_ASTRO, GLOB_ASTRO_TS, GLOB_CSS, GLOB_EXCLUDE, GLOB_GRAPHQL, GLOB_HTML, GLOB_JS, GLOB_JSON, GLOB_JSON5, GLOB_JSONC, GLOB_JSX, GLOB_LESS, GLOB_MARKDOWN, GLOB_MARKDOWN_CODE, GLOB_MARKDOWN_IN_MARKDOWN, GLOB_POSTCSS, GLOB_SCSS, GLOB_SRC, GLOB_SRC_EXT, GLOB_STYLE, GLOB_SVELTE, GLOB_SVG, GLOB_TESTS, GLOB_TOML, GLOB_TS, GLOB_TSX, GLOB_VUE, GLOB_XML, GLOB_YAML, type OptionsComponentExts, type OptionsConfig, type OptionsFiles, type OptionsFormatters, type OptionsHasTypeScript, type OptionsIsInEditor, type OptionsOverrides, type OptionsProjectType, type OptionsRegExp, type OptionsStylistic, type OptionsTypeScriptParserOptions, type OptionsTypeScriptWithTypes, type OptionsTypescript, type OptionsUnicorn, type OptionsUnoCSS, type OptionsVue, type ResolvedOptions, type Rules, type StylisticConfig, StylisticConfigDefaults, type StylisticOptions, type TypedFlatConfigItem, astro, combine, command, comments, whoj as default, defaultPluginRenaming, disables, ensurePackages, formatters, getOverrides, ignores, imports, interopDefault, isInEditorEnv, isInGitHooksOrLintStaged, isPackageInScope, javascript, jsdoc, jsonc, jsx, markdown, node, parserPlain, perfectionist, react, regexp, renamePluginInConfigs, renameRules, resolveSubOptions, solid, sortPackageJson, sortTsconfig, stylistic, svelte, test, toArray, toml, typescript, unicorn, unocss, vue, whoj, yaml };
|