@eslint-react/core 2.6.1-beta.1 → 2.6.1-beta.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.d.ts +47 -53
- package/package.json +6 -6
package/dist/index.d.ts
CHANGED
|
@@ -14,28 +14,28 @@ type ComponentDetectionHint = bigint;
|
|
|
14
14
|
*/
|
|
15
15
|
declare const ComponentDetectionHint: {
|
|
16
16
|
/**
|
|
17
|
-
|
|
18
|
-
|
|
17
|
+
* Skip function component created by React.memo
|
|
18
|
+
*/
|
|
19
19
|
readonly SkipMemo: bigint;
|
|
20
20
|
/**
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
* Skip function component created by React.forwardRef
|
|
22
|
+
*/
|
|
23
23
|
readonly SkipForwardRef: bigint;
|
|
24
24
|
/**
|
|
25
|
-
|
|
26
|
-
|
|
25
|
+
* Skip function component defined as array map argument
|
|
26
|
+
*/
|
|
27
27
|
readonly SkipArrayMapArgument: bigint;
|
|
28
28
|
/**
|
|
29
|
-
|
|
30
|
-
|
|
29
|
+
* Skip function component defined on object method
|
|
30
|
+
*/
|
|
31
31
|
readonly SkipObjectMethod: bigint;
|
|
32
32
|
/**
|
|
33
|
-
|
|
34
|
-
|
|
33
|
+
* Skip function component defined on class method
|
|
34
|
+
*/
|
|
35
35
|
readonly SkipClassMethod: bigint;
|
|
36
36
|
/**
|
|
37
|
-
|
|
38
|
-
|
|
37
|
+
* Skip function component defined on class property
|
|
38
|
+
*/
|
|
39
39
|
readonly SkipClassProperty: bigint;
|
|
40
40
|
readonly None: 0n;
|
|
41
41
|
readonly SkipUndefined: bigint;
|
|
@@ -84,17 +84,11 @@ interface SemanticNode {
|
|
|
84
84
|
//#region src/component/component-flag.d.ts
|
|
85
85
|
type ComponentFlag = bigint;
|
|
86
86
|
declare const ComponentFlag: {
|
|
87
|
-
/** No flags set */
|
|
88
|
-
|
|
89
|
-
/** Indicates the component is
|
|
90
|
-
|
|
91
|
-
/** Indicates the component
|
|
92
|
-
CreateElement: bigint;
|
|
93
|
-
/** Indicates the component is memoized (e.g., React.memo) */
|
|
94
|
-
Memo: bigint;
|
|
95
|
-
/** Indicates the component forwards a ref (e.g., React.forwardRef) */
|
|
96
|
-
ForwardRef: bigint;
|
|
97
|
-
/** Indicates the component is asynchronous */
|
|
87
|
+
/** No flags set */None: bigint; /** Indicates the component is a pure component (e.g., extends PureComponent) */
|
|
88
|
+
PureComponent: bigint; /** Indicates the component creates elements using `createElement` instead of JSX */
|
|
89
|
+
CreateElement: bigint; /** Indicates the component is memoized (e.g., React.memo) */
|
|
90
|
+
Memo: bigint; /** Indicates the component forwards a ref (e.g., React.forwardRef) */
|
|
91
|
+
ForwardRef: bigint; /** Indicates the component is asynchronous */
|
|
98
92
|
Async: bigint;
|
|
99
93
|
};
|
|
100
94
|
//#endregion
|
|
@@ -104,36 +98,36 @@ declare const ComponentFlag: {
|
|
|
104
98
|
*/
|
|
105
99
|
interface FunctionComponent extends SemanticNode {
|
|
106
100
|
/**
|
|
107
|
-
|
|
108
|
-
|
|
101
|
+
* The identifier or identifier sequence of the component
|
|
102
|
+
*/
|
|
109
103
|
id: unit | TSESTree.Identifier | TSESTree.Identifier[];
|
|
110
104
|
/**
|
|
111
|
-
|
|
112
|
-
|
|
105
|
+
* The kind of component
|
|
106
|
+
*/
|
|
113
107
|
kind: "function";
|
|
114
108
|
/**
|
|
115
|
-
|
|
116
|
-
|
|
109
|
+
* The AST node of the function
|
|
110
|
+
*/
|
|
117
111
|
node: AST.TSESTreeFunction;
|
|
118
112
|
/**
|
|
119
|
-
|
|
120
|
-
|
|
113
|
+
* Flags describing the component's characteristics
|
|
114
|
+
*/
|
|
121
115
|
flag: ComponentFlag;
|
|
122
116
|
/**
|
|
123
|
-
|
|
124
|
-
|
|
117
|
+
* Hint for how the component was detected
|
|
118
|
+
*/
|
|
125
119
|
hint: ComponentDetectionHint;
|
|
126
120
|
/**
|
|
127
|
-
|
|
128
|
-
|
|
121
|
+
* The initialization path of the function
|
|
122
|
+
*/
|
|
129
123
|
initPath: unit | AST.FunctionInitPath;
|
|
130
124
|
/**
|
|
131
|
-
|
|
132
|
-
|
|
125
|
+
* List of hook calls within the component
|
|
126
|
+
*/
|
|
133
127
|
hookCalls: TSESTree.CallExpression[];
|
|
134
128
|
/**
|
|
135
|
-
|
|
136
|
-
|
|
129
|
+
* The display name of the component
|
|
130
|
+
*/
|
|
137
131
|
displayName: unit | TSESTree.Expression;
|
|
138
132
|
}
|
|
139
133
|
/**
|
|
@@ -141,32 +135,32 @@ interface FunctionComponent extends SemanticNode {
|
|
|
141
135
|
*/
|
|
142
136
|
interface ClassComponent extends SemanticNode {
|
|
143
137
|
/**
|
|
144
|
-
|
|
145
|
-
|
|
138
|
+
* The identifier of the component
|
|
139
|
+
*/
|
|
146
140
|
id: unit | TSESTree.Identifier;
|
|
147
141
|
/**
|
|
148
|
-
|
|
149
|
-
|
|
142
|
+
* The kind of component
|
|
143
|
+
*/
|
|
150
144
|
kind: "class";
|
|
151
145
|
/**
|
|
152
|
-
|
|
153
|
-
|
|
146
|
+
* The AST node of the class
|
|
147
|
+
*/
|
|
154
148
|
node: AST.TSESTreeClass;
|
|
155
149
|
/**
|
|
156
|
-
|
|
157
|
-
|
|
150
|
+
* Flags describing the component's characteristics
|
|
151
|
+
*/
|
|
158
152
|
flag: ComponentFlag;
|
|
159
153
|
/**
|
|
160
|
-
|
|
161
|
-
|
|
154
|
+
* Hint for how the component was detected
|
|
155
|
+
*/
|
|
162
156
|
hint: ComponentDetectionHint;
|
|
163
157
|
/**
|
|
164
|
-
|
|
165
|
-
|
|
158
|
+
* List of methods and properties in the class
|
|
159
|
+
*/
|
|
166
160
|
methods: AST.TSESTreeMethodOrProperty[];
|
|
167
161
|
/**
|
|
168
|
-
|
|
169
|
-
|
|
162
|
+
* The display name of the component
|
|
163
|
+
*/
|
|
170
164
|
displayName: unit | TSESTree.Expression;
|
|
171
165
|
}
|
|
172
166
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eslint-react/core",
|
|
3
|
-
"version": "2.6.1-beta.
|
|
3
|
+
"version": "2.6.1-beta.2",
|
|
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,13 +35,13 @@
|
|
|
35
35
|
"@typescript-eslint/utils": "^8.53.0",
|
|
36
36
|
"birecord": "^0.1.1",
|
|
37
37
|
"ts-pattern": "^5.9.0",
|
|
38
|
-
"@eslint-react/ast": "2.6.1-beta.
|
|
39
|
-
"@eslint-react/eff": "2.6.1-beta.
|
|
40
|
-
"@eslint-react/shared": "2.6.1-beta.
|
|
41
|
-
"@eslint-react/var": "2.6.1-beta.
|
|
38
|
+
"@eslint-react/ast": "2.6.1-beta.2",
|
|
39
|
+
"@eslint-react/eff": "2.6.1-beta.2",
|
|
40
|
+
"@eslint-react/shared": "2.6.1-beta.2",
|
|
41
|
+
"@eslint-react/var": "2.6.1-beta.2"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
|
-
"tsdown": "^0.20.0-beta.
|
|
44
|
+
"tsdown": "^0.20.0-beta.3",
|
|
45
45
|
"@local/configs": "0.0.0"
|
|
46
46
|
},
|
|
47
47
|
"peerDependencies": {
|