@eslint-react/jsx 1.15.0 → 1.15.1-next.2
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.js +4 -4
- package/dist/index.mjs +4 -4
- package/package.json +9 -9
package/dist/index.js
CHANGED
|
@@ -126,6 +126,8 @@ function findPropInAttributes(attributes, initialScope) {
|
|
|
126
126
|
return getPropName(attr) === propName;
|
|
127
127
|
case types.AST_NODE_TYPES.JSXSpreadAttribute:
|
|
128
128
|
switch (attr.argument.type) {
|
|
129
|
+
case types.AST_NODE_TYPES.CallExpression:
|
|
130
|
+
return false;
|
|
129
131
|
case types.AST_NODE_TYPES.Identifier: {
|
|
130
132
|
const { name } = attr.argument;
|
|
131
133
|
const maybeInit = tools.O.flatMap(
|
|
@@ -137,12 +139,10 @@ function findPropInAttributes(attributes, initialScope) {
|
|
|
137
139
|
if (!AST__namespace.is(types.AST_NODE_TYPES.ObjectExpression)(init)) return false;
|
|
138
140
|
return tools.O.isSome(findPropInProperties(init.properties, initialScope)(propName));
|
|
139
141
|
}
|
|
140
|
-
case types.AST_NODE_TYPES.ObjectExpression:
|
|
141
|
-
return tools.O.isSome(findPropInProperties(attr.argument.properties, initialScope)(propName));
|
|
142
142
|
case types.AST_NODE_TYPES.MemberExpression:
|
|
143
143
|
return false;
|
|
144
|
-
case types.AST_NODE_TYPES.
|
|
145
|
-
return
|
|
144
|
+
case types.AST_NODE_TYPES.ObjectExpression:
|
|
145
|
+
return tools.O.isSome(findPropInProperties(attr.argument.properties, initialScope)(propName));
|
|
146
146
|
default:
|
|
147
147
|
return false;
|
|
148
148
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -103,6 +103,8 @@ function findPropInAttributes(attributes, initialScope) {
|
|
|
103
103
|
return getPropName(attr) === propName;
|
|
104
104
|
case AST_NODE_TYPES.JSXSpreadAttribute:
|
|
105
105
|
switch (attr.argument.type) {
|
|
106
|
+
case AST_NODE_TYPES.CallExpression:
|
|
107
|
+
return false;
|
|
106
108
|
case AST_NODE_TYPES.Identifier: {
|
|
107
109
|
const { name } = attr.argument;
|
|
108
110
|
const maybeInit = O.flatMap(
|
|
@@ -114,12 +116,10 @@ function findPropInAttributes(attributes, initialScope) {
|
|
|
114
116
|
if (!AST.is(AST_NODE_TYPES.ObjectExpression)(init)) return false;
|
|
115
117
|
return O.isSome(findPropInProperties(init.properties, initialScope)(propName));
|
|
116
118
|
}
|
|
117
|
-
case AST_NODE_TYPES.ObjectExpression:
|
|
118
|
-
return O.isSome(findPropInProperties(attr.argument.properties, initialScope)(propName));
|
|
119
119
|
case AST_NODE_TYPES.MemberExpression:
|
|
120
120
|
return false;
|
|
121
|
-
case AST_NODE_TYPES.
|
|
122
|
-
return
|
|
121
|
+
case AST_NODE_TYPES.ObjectExpression:
|
|
122
|
+
return O.isSome(findPropInProperties(attr.argument.properties, initialScope)(propName));
|
|
123
123
|
default:
|
|
124
124
|
return false;
|
|
125
125
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eslint-react/jsx",
|
|
3
|
-
"version": "1.15.
|
|
3
|
+
"version": "1.15.1-next.2",
|
|
4
4
|
"description": "ESLint React's TSESTree AST utility module for static analysis of JSX.",
|
|
5
5
|
"homepage": "https://github.com/rel1cx/eslint-react",
|
|
6
6
|
"bugs": {
|
|
@@ -35,14 +35,14 @@
|
|
|
35
35
|
"./package.json"
|
|
36
36
|
],
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@typescript-eslint/scope-manager": "^8.
|
|
39
|
-
"@typescript-eslint/types": "^8.
|
|
40
|
-
"@typescript-eslint/utils": "^8.
|
|
41
|
-
"ts-pattern": "^5.
|
|
42
|
-
"@eslint-react/ast": "1.15.
|
|
43
|
-
"@eslint-react/tools": "1.15.
|
|
44
|
-
"@eslint-react/
|
|
45
|
-
"@eslint-react/
|
|
38
|
+
"@typescript-eslint/scope-manager": "^8.10.0",
|
|
39
|
+
"@typescript-eslint/types": "^8.10.0",
|
|
40
|
+
"@typescript-eslint/utils": "^8.10.0",
|
|
41
|
+
"ts-pattern": "^5.5.0",
|
|
42
|
+
"@eslint-react/ast": "1.15.1-next.2",
|
|
43
|
+
"@eslint-react/tools": "1.15.1-next.2",
|
|
44
|
+
"@eslint-react/types": "1.15.1-next.2",
|
|
45
|
+
"@eslint-react/var": "1.15.1-next.2"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
48
|
"tsup": "^8.3.0"
|