@eslint-react/core 1.38.0-next.9 → 1.38.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/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +6 -6
- package/dist/index.mjs +6 -6
- package/package.json +11 -11
package/dist/index.d.mts
CHANGED
|
@@ -20,9 +20,9 @@ declare const ERComponentHint: {
|
|
|
20
20
|
*/
|
|
21
21
|
readonly SkipForwardRef: bigint;
|
|
22
22
|
/**
|
|
23
|
-
* Skip function component defined
|
|
23
|
+
* Skip function component defined as array map argument
|
|
24
24
|
*/
|
|
25
|
-
readonly
|
|
25
|
+
readonly SkipArrayMapArgument: bigint;
|
|
26
26
|
/**
|
|
27
27
|
* Skip function component defined on object method
|
|
28
28
|
*/
|
package/dist/index.d.ts
CHANGED
|
@@ -20,9 +20,9 @@ declare const ERComponentHint: {
|
|
|
20
20
|
*/
|
|
21
21
|
readonly SkipForwardRef: bigint;
|
|
22
22
|
/**
|
|
23
|
-
* Skip function component defined
|
|
23
|
+
* Skip function component defined as array map argument
|
|
24
24
|
*/
|
|
25
|
-
readonly
|
|
25
|
+
readonly SkipArrayMapArgument: bigint;
|
|
26
26
|
/**
|
|
27
27
|
* Skip function component defined on object method
|
|
28
28
|
*/
|
package/dist/index.js
CHANGED
|
@@ -829,9 +829,9 @@ var ERComponentHint = {
|
|
|
829
829
|
*/
|
|
830
830
|
SkipForwardRef: 1n << 65n,
|
|
831
831
|
/**
|
|
832
|
-
* Skip function component defined
|
|
832
|
+
* Skip function component defined as array map argument
|
|
833
833
|
*/
|
|
834
|
-
|
|
834
|
+
SkipArrayMapArgument: 1n << 66n,
|
|
835
835
|
/**
|
|
836
836
|
* Skip function component defined on object method
|
|
837
837
|
*/
|
|
@@ -845,7 +845,7 @@ var ERComponentHint = {
|
|
|
845
845
|
*/
|
|
846
846
|
SkipClassProperty: 1n << 69n
|
|
847
847
|
};
|
|
848
|
-
var DEFAULT_COMPONENT_HINT = 0n | ERComponentHint.SkipBooleanLiteral | ERComponentHint.SkipEmptyArray | ERComponentHint.
|
|
848
|
+
var DEFAULT_COMPONENT_HINT = 0n | ERComponentHint.SkipBooleanLiteral | ERComponentHint.SkipEmptyArray | ERComponentHint.SkipArrayMapArgument | ERComponentHint.SkipNumberLiteral | ERComponentHint.SkipStringLiteral | ERComponentHint.SkipUndefined | ERComponentHint.StrictArray | ERComponentHint.StrictConditional | ERComponentHint.StrictLogical;
|
|
849
849
|
|
|
850
850
|
// src/component/component-flag.ts
|
|
851
851
|
var ERComponentFlag = {
|
|
@@ -959,9 +959,6 @@ function hasValidHierarchy(context, node, hint) {
|
|
|
959
959
|
if (isChildrenOfCreateElement(context, node) || isFunctionOfRenderMethod(node)) {
|
|
960
960
|
return false;
|
|
961
961
|
}
|
|
962
|
-
if (hint & ERComponentHint.SkipMapCallback && AST6__namespace.isMapCallLoose(node.parent)) {
|
|
963
|
-
return false;
|
|
964
|
-
}
|
|
965
962
|
if (hint & ERComponentHint.SkipObjectMethod && isFunctionOfObjectMethod(node.parent)) {
|
|
966
963
|
return false;
|
|
967
964
|
}
|
|
@@ -971,6 +968,9 @@ function hasValidHierarchy(context, node, hint) {
|
|
|
971
968
|
if (hint & ERComponentHint.SkipClassProperty && isFunctionOfClassProperty(node.parent)) {
|
|
972
969
|
return false;
|
|
973
970
|
}
|
|
971
|
+
if (hint & ERComponentHint.SkipArrayMapArgument && AST6__namespace.isArrayMapCallLoose(node.parent)) {
|
|
972
|
+
return false;
|
|
973
|
+
}
|
|
974
974
|
const boundaryNode = AST6__namespace.findParentNode(
|
|
975
975
|
node,
|
|
976
976
|
AST6__namespace.isOneOf([
|
package/dist/index.mjs
CHANGED
|
@@ -802,9 +802,9 @@ var ERComponentHint = {
|
|
|
802
802
|
*/
|
|
803
803
|
SkipForwardRef: 1n << 65n,
|
|
804
804
|
/**
|
|
805
|
-
* Skip function component defined
|
|
805
|
+
* Skip function component defined as array map argument
|
|
806
806
|
*/
|
|
807
|
-
|
|
807
|
+
SkipArrayMapArgument: 1n << 66n,
|
|
808
808
|
/**
|
|
809
809
|
* Skip function component defined on object method
|
|
810
810
|
*/
|
|
@@ -818,7 +818,7 @@ var ERComponentHint = {
|
|
|
818
818
|
*/
|
|
819
819
|
SkipClassProperty: 1n << 69n
|
|
820
820
|
};
|
|
821
|
-
var DEFAULT_COMPONENT_HINT = 0n | ERComponentHint.SkipBooleanLiteral | ERComponentHint.SkipEmptyArray | ERComponentHint.
|
|
821
|
+
var DEFAULT_COMPONENT_HINT = 0n | ERComponentHint.SkipBooleanLiteral | ERComponentHint.SkipEmptyArray | ERComponentHint.SkipArrayMapArgument | ERComponentHint.SkipNumberLiteral | ERComponentHint.SkipStringLiteral | ERComponentHint.SkipUndefined | ERComponentHint.StrictArray | ERComponentHint.StrictConditional | ERComponentHint.StrictLogical;
|
|
822
822
|
|
|
823
823
|
// src/component/component-flag.ts
|
|
824
824
|
var ERComponentFlag = {
|
|
@@ -932,9 +932,6 @@ function hasValidHierarchy(context, node, hint) {
|
|
|
932
932
|
if (isChildrenOfCreateElement(context, node) || isFunctionOfRenderMethod(node)) {
|
|
933
933
|
return false;
|
|
934
934
|
}
|
|
935
|
-
if (hint & ERComponentHint.SkipMapCallback && AST6.isMapCallLoose(node.parent)) {
|
|
936
|
-
return false;
|
|
937
|
-
}
|
|
938
935
|
if (hint & ERComponentHint.SkipObjectMethod && isFunctionOfObjectMethod(node.parent)) {
|
|
939
936
|
return false;
|
|
940
937
|
}
|
|
@@ -944,6 +941,9 @@ function hasValidHierarchy(context, node, hint) {
|
|
|
944
941
|
if (hint & ERComponentHint.SkipClassProperty && isFunctionOfClassProperty(node.parent)) {
|
|
945
942
|
return false;
|
|
946
943
|
}
|
|
944
|
+
if (hint & ERComponentHint.SkipArrayMapArgument && AST6.isArrayMapCallLoose(node.parent)) {
|
|
945
|
+
return false;
|
|
946
|
+
}
|
|
947
947
|
const boundaryNode = AST6.findParentNode(
|
|
948
948
|
node,
|
|
949
949
|
AST6.isOneOf([
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eslint-react/core",
|
|
3
|
-
"version": "1.38.0
|
|
3
|
+
"version": "1.38.0",
|
|
4
4
|
"description": "ESLint React's ESLint utility module for static analysis of React core APIs and patterns.",
|
|
5
5
|
"homepage": "https://github.com/Rel1cx/eslint-react",
|
|
6
6
|
"bugs": {
|
|
@@ -35,18 +35,18 @@
|
|
|
35
35
|
"./package.json"
|
|
36
36
|
],
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@typescript-eslint/scope-manager": "^8.
|
|
39
|
-
"@typescript-eslint/type-utils": "^8.
|
|
40
|
-
"@typescript-eslint/types": "^8.
|
|
41
|
-
"@typescript-eslint/utils": "^8.
|
|
38
|
+
"@typescript-eslint/scope-manager": "^8.28.0",
|
|
39
|
+
"@typescript-eslint/type-utils": "^8.28.0",
|
|
40
|
+
"@typescript-eslint/types": "^8.28.0",
|
|
41
|
+
"@typescript-eslint/utils": "^8.28.0",
|
|
42
42
|
"birecord": "^0.1.1",
|
|
43
43
|
"ts-pattern": "^5.6.2",
|
|
44
|
-
"@eslint-react/
|
|
45
|
-
"@eslint-react/
|
|
46
|
-
"@eslint-react/
|
|
47
|
-
"@eslint-react/
|
|
48
|
-
"@eslint-react/
|
|
49
|
-
"@eslint-react/
|
|
44
|
+
"@eslint-react/eff": "1.38.0",
|
|
45
|
+
"@eslint-react/ast": "1.38.0",
|
|
46
|
+
"@eslint-react/jsx": "1.38.0",
|
|
47
|
+
"@eslint-react/var": "1.38.0",
|
|
48
|
+
"@eslint-react/kit": "1.38.0",
|
|
49
|
+
"@eslint-react/shared": "1.38.0"
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
52
|
"tsup": "^8.4.0",
|