@eslint-react/core 1.24.0-next.12 → 1.24.0-next.13
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 -7
- package/dist/index.d.ts +2 -7
- package/dist/index.js +22 -27
- package/dist/index.mjs +19 -23
- package/package.json +6 -6
package/dist/index.d.mts
CHANGED
|
@@ -166,9 +166,6 @@ declare function isFunctionOfRenderMethod(node: AST.TSESTreeFunction): boolean;
|
|
|
166
166
|
*/
|
|
167
167
|
declare function isInsideRenderMethod(node: TSESTree.Node): boolean;
|
|
168
168
|
|
|
169
|
-
type EREffectMethodKind = "useEffect" | "useInsertionEffect" | "useLayoutEffect";
|
|
170
|
-
type ERLifecycleMethodKind = "componentDidMount" | "componentWillUnmount";
|
|
171
|
-
|
|
172
169
|
declare const RE_COMPONENT_NAME: RegExp;
|
|
173
170
|
declare function getComponentNameFromIdentifier(node: TSESTree.Identifier | TSESTree.Identifier[] | _): string | undefined;
|
|
174
171
|
declare function isComponentName(name: string): boolean;
|
|
@@ -252,7 +249,7 @@ declare function isClassComponent(node: TSESTree.Node): node is AST.TSESTreeClas
|
|
|
252
249
|
*/
|
|
253
250
|
declare function isPureComponent(node: TSESTree.Node): boolean;
|
|
254
251
|
|
|
255
|
-
type EREffectKind = "
|
|
252
|
+
type EREffectKind = "useEffect" | "useLayoutEffect" | "useInsertionEffect";
|
|
256
253
|
|
|
257
254
|
declare function isFunctionOfUseEffectSetup(node: TSESTree.Node | _): boolean | undefined;
|
|
258
255
|
declare function isFunctionOfUseEffectCleanup(node: TSESTree.Node): boolean | undefined;
|
|
@@ -330,8 +327,6 @@ interface ERSemanticEntry {
|
|
|
330
327
|
phase: ERPhaseKind;
|
|
331
328
|
}
|
|
332
329
|
|
|
333
|
-
declare const getId: () => string;
|
|
334
|
-
|
|
335
330
|
/**
|
|
336
331
|
* Checks if the given node is a call expression to the given function or method of the pragma
|
|
337
332
|
* @param name The name of the function or method to check
|
|
@@ -2584,4 +2579,4 @@ declare const isMemoCall: {
|
|
|
2584
2579
|
(node: Node, context: _eslint_react_shared.RuleContext): node is CallExpression;
|
|
2585
2580
|
};
|
|
2586
2581
|
|
|
2587
|
-
export { type ComponentCollectorOptions, DEFAULT_COMPONENT_HINT, type ERClassComponent, ERClassComponentFlag, type ERComponent, ERComponentHint, type ERComponentKind, type EREffectKind, type
|
|
2582
|
+
export { type ComponentCollectorOptions, DEFAULT_COMPONENT_HINT, type ERClassComponent, ERClassComponentFlag, type ERComponent, ERComponentHint, type ERComponentKind, type EREffectKind, type EREffectPhaseKind, type ERFunctionComponent, ERFunctionComponentFlag, type ERHook, type ERHookKind, type ERLifecyclePhaseKind, type ERPhaseKind, ERPhaseRelevance, type ERSemanticEntry, type ERSemanticNode, type ERStateKind, RE_COMPONENT_NAME, RE_HOOK_NAME, getComponentNameFromIdentifier, getFunctionComponentIdentifier, hasNoneOrValidComponentName, isCallFromReact, isCallFromReactMember, isChildrenCount, isChildrenCountCall, isChildrenForEach, isChildrenForEachCall, isChildrenMap, isChildrenMapCall, isChildrenOfCreateElement, isChildrenOnly, isChildrenOnlyCall, isChildrenToArray, isChildrenToArrayCall, isClassComponent, isCloneElement, isCloneElementCall, isComponentDidCatch, isComponentDidMount, isComponentName, isComponentWillUnmount, isCreateContext, isCreateContextCall, isCreateElement, isCreateElementCall, isCreateRef, isCreateRefCall, isDeclaredInRenderPropLoose, isDirectValueOfRenderPropertyLoose, isForwardRef, isForwardRefCall, isFromReact, isFromReactMember, isFunctionOfComponentDidMount, isFunctionOfComponentWillUnmount, isFunctionOfRenderMethod, isFunctionOfUseEffectCleanup, isFunctionOfUseEffectSetup, isGetDerivedStateFromError, isGetDerivedStateFromProps, isInitializedFromReact, isInsideCreateElementProps, isInsideReactHook, isInsideRenderMethod, isInversePhase, isMemo, isMemoCall, isPureComponent, isReactAPICallWithName, isReactAPIWithName, isReactHook, isReactHookCall, isReactHookCallWithName, isReactHookCallWithNameAlias, isReactHookCallWithNameLoose, isReactHookName, isRenderFunctionLoose, isRenderMethodLike, isRenderPropLoose, isThisSetState, isUseCallbackCall, isUseContextCall, isUseDebugValueCall, isUseDeferredValueCall, isUseEffectCall, isUseEffectCallLoose, isUseIdCall, isUseImperativeHandleCall, isUseInsertionEffectCall, isUseLayoutEffectCall, isUseMemoCall, isUseReducerCall, isUseRefCall, isUseStateCall, isUseSyncExternalStoreCall, isUseTransitionCall, useComponentCollector, useComponentCollectorLegacy, useHookCollector };
|
package/dist/index.d.ts
CHANGED
|
@@ -166,9 +166,6 @@ declare function isFunctionOfRenderMethod(node: AST.TSESTreeFunction): boolean;
|
|
|
166
166
|
*/
|
|
167
167
|
declare function isInsideRenderMethod(node: TSESTree.Node): boolean;
|
|
168
168
|
|
|
169
|
-
type EREffectMethodKind = "useEffect" | "useInsertionEffect" | "useLayoutEffect";
|
|
170
|
-
type ERLifecycleMethodKind = "componentDidMount" | "componentWillUnmount";
|
|
171
|
-
|
|
172
169
|
declare const RE_COMPONENT_NAME: RegExp;
|
|
173
170
|
declare function getComponentNameFromIdentifier(node: TSESTree.Identifier | TSESTree.Identifier[] | _): string | undefined;
|
|
174
171
|
declare function isComponentName(name: string): boolean;
|
|
@@ -252,7 +249,7 @@ declare function isClassComponent(node: TSESTree.Node): node is AST.TSESTreeClas
|
|
|
252
249
|
*/
|
|
253
250
|
declare function isPureComponent(node: TSESTree.Node): boolean;
|
|
254
251
|
|
|
255
|
-
type EREffectKind = "
|
|
252
|
+
type EREffectKind = "useEffect" | "useLayoutEffect" | "useInsertionEffect";
|
|
256
253
|
|
|
257
254
|
declare function isFunctionOfUseEffectSetup(node: TSESTree.Node | _): boolean | undefined;
|
|
258
255
|
declare function isFunctionOfUseEffectCleanup(node: TSESTree.Node): boolean | undefined;
|
|
@@ -330,8 +327,6 @@ interface ERSemanticEntry {
|
|
|
330
327
|
phase: ERPhaseKind;
|
|
331
328
|
}
|
|
332
329
|
|
|
333
|
-
declare const getId: () => string;
|
|
334
|
-
|
|
335
330
|
/**
|
|
336
331
|
* Checks if the given node is a call expression to the given function or method of the pragma
|
|
337
332
|
* @param name The name of the function or method to check
|
|
@@ -2584,4 +2579,4 @@ declare const isMemoCall: {
|
|
|
2584
2579
|
(node: Node, context: _eslint_react_shared.RuleContext): node is CallExpression;
|
|
2585
2580
|
};
|
|
2586
2581
|
|
|
2587
|
-
export { type ComponentCollectorOptions, DEFAULT_COMPONENT_HINT, type ERClassComponent, ERClassComponentFlag, type ERComponent, ERComponentHint, type ERComponentKind, type EREffectKind, type
|
|
2582
|
+
export { type ComponentCollectorOptions, DEFAULT_COMPONENT_HINT, type ERClassComponent, ERClassComponentFlag, type ERComponent, ERComponentHint, type ERComponentKind, type EREffectKind, type EREffectPhaseKind, type ERFunctionComponent, ERFunctionComponentFlag, type ERHook, type ERHookKind, type ERLifecyclePhaseKind, type ERPhaseKind, ERPhaseRelevance, type ERSemanticEntry, type ERSemanticNode, type ERStateKind, RE_COMPONENT_NAME, RE_HOOK_NAME, getComponentNameFromIdentifier, getFunctionComponentIdentifier, hasNoneOrValidComponentName, isCallFromReact, isCallFromReactMember, isChildrenCount, isChildrenCountCall, isChildrenForEach, isChildrenForEachCall, isChildrenMap, isChildrenMapCall, isChildrenOfCreateElement, isChildrenOnly, isChildrenOnlyCall, isChildrenToArray, isChildrenToArrayCall, isClassComponent, isCloneElement, isCloneElementCall, isComponentDidCatch, isComponentDidMount, isComponentName, isComponentWillUnmount, isCreateContext, isCreateContextCall, isCreateElement, isCreateElementCall, isCreateRef, isCreateRefCall, isDeclaredInRenderPropLoose, isDirectValueOfRenderPropertyLoose, isForwardRef, isForwardRefCall, isFromReact, isFromReactMember, isFunctionOfComponentDidMount, isFunctionOfComponentWillUnmount, isFunctionOfRenderMethod, isFunctionOfUseEffectCleanup, isFunctionOfUseEffectSetup, isGetDerivedStateFromError, isGetDerivedStateFromProps, isInitializedFromReact, isInsideCreateElementProps, isInsideReactHook, isInsideRenderMethod, isInversePhase, isMemo, isMemoCall, isPureComponent, isReactAPICallWithName, isReactAPIWithName, isReactHook, isReactHookCall, isReactHookCallWithName, isReactHookCallWithNameAlias, isReactHookCallWithNameLoose, isReactHookName, isRenderFunctionLoose, isRenderMethodLike, isRenderPropLoose, isThisSetState, isUseCallbackCall, isUseContextCall, isUseDebugValueCall, isUseDeferredValueCall, isUseEffectCall, isUseEffectCallLoose, isUseIdCall, isUseImperativeHandleCall, isUseInsertionEffectCall, isUseLayoutEffectCall, isUseMemoCall, isUseReducerCall, isUseRefCall, isUseStateCall, isUseSyncExternalStoreCall, isUseTransitionCall, useComponentCollector, useComponentCollectorLegacy, useHookCollector };
|
package/dist/index.js
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
var AST8 = require('@eslint-react/ast');
|
|
4
4
|
var eff = require('@eslint-react/eff');
|
|
5
5
|
var JSX3 = require('@eslint-react/jsx');
|
|
6
|
-
var types = require('@typescript-eslint/types');
|
|
7
6
|
var shared = require('@eslint-react/shared');
|
|
7
|
+
var types = require('@typescript-eslint/types');
|
|
8
8
|
var VAR = require('@eslint-react/var');
|
|
9
9
|
var birecord = require('birecord');
|
|
10
10
|
|
|
@@ -34,10 +34,6 @@ var VAR__namespace = /*#__PURE__*/_interopNamespace(VAR);
|
|
|
34
34
|
var birecord__default = /*#__PURE__*/_interopDefault(birecord);
|
|
35
35
|
|
|
36
36
|
// src/component/component-collector.ts
|
|
37
|
-
|
|
38
|
-
// src/utils/get-id.ts
|
|
39
|
-
var id = 0n;
|
|
40
|
-
var getId = () => (id++).toString();
|
|
41
37
|
function isInitializedFromReact(name, initialScope, importSource = "react") {
|
|
42
38
|
return name.toLowerCase() === "react" || VAR__namespace.isInitializedFromSource(
|
|
43
39
|
name,
|
|
@@ -171,8 +167,8 @@ function isReactHookName(name) {
|
|
|
171
167
|
// src/hook/is.ts
|
|
172
168
|
function isReactHook(node) {
|
|
173
169
|
if (node == null) return eff._;
|
|
174
|
-
const
|
|
175
|
-
return
|
|
170
|
+
const id = AST8__namespace.getFunctionIdentifier(node);
|
|
171
|
+
return id?.name != null && isReactHookName(id.name);
|
|
176
172
|
}
|
|
177
173
|
function isReactHookCall(node) {
|
|
178
174
|
if (node == null) return false;
|
|
@@ -267,13 +263,13 @@ function useHookCollector() {
|
|
|
267
263
|
const hooks = /* @__PURE__ */ new Map();
|
|
268
264
|
const fEntries = [];
|
|
269
265
|
const onFunctionEnter = (node) => {
|
|
270
|
-
const
|
|
271
|
-
const name =
|
|
266
|
+
const id = AST8__namespace.getFunctionIdentifier(node);
|
|
267
|
+
const name = id?.name;
|
|
272
268
|
if (name != null && isReactHookName(name)) {
|
|
273
|
-
const key = getId();
|
|
269
|
+
const key = shared.getId();
|
|
274
270
|
fEntries.push({ key, node });
|
|
275
271
|
hooks.set(key, {
|
|
276
|
-
id
|
|
272
|
+
id,
|
|
277
273
|
key,
|
|
278
274
|
kind: "function",
|
|
279
275
|
name,
|
|
@@ -442,9 +438,9 @@ function isComponentName(name) {
|
|
|
442
438
|
return RE_COMPONENT_NAME.test(name);
|
|
443
439
|
}
|
|
444
440
|
function hasNoneOrValidComponentName(node, context) {
|
|
445
|
-
const
|
|
446
|
-
if (
|
|
447
|
-
const name = Array.isArray(
|
|
441
|
+
const id = getFunctionComponentIdentifier(node, context);
|
|
442
|
+
if (id == null) return true;
|
|
443
|
+
const name = Array.isArray(id) ? id.at(-1)?.name : id.name;
|
|
448
444
|
return name != null && isComponentName(name);
|
|
449
445
|
}
|
|
450
446
|
|
|
@@ -495,7 +491,7 @@ function useComponentCollector(context, hint = DEFAULT_COMPONENT_HINT, options =
|
|
|
495
491
|
const functionEntries = [];
|
|
496
492
|
const getCurrentEntry = () => functionEntries.at(-1);
|
|
497
493
|
const onFunctionEnter = (node) => {
|
|
498
|
-
const key = getId();
|
|
494
|
+
const key = shared.getId();
|
|
499
495
|
functionEntries.push({ key, node, hookCalls: [], isComponent: false });
|
|
500
496
|
};
|
|
501
497
|
const onFunctionExit = () => {
|
|
@@ -536,11 +532,11 @@ function useComponentCollector(context, hint = DEFAULT_COMPONENT_HINT, options =
|
|
|
536
532
|
return;
|
|
537
533
|
}
|
|
538
534
|
const initPath = AST8__namespace.getFunctionInitPath(entry.node);
|
|
539
|
-
const
|
|
540
|
-
const name = getComponentNameFromIdentifier(
|
|
541
|
-
const key = getId();
|
|
535
|
+
const id = getFunctionComponentIdentifier(entry.node, context);
|
|
536
|
+
const name = getComponentNameFromIdentifier(id);
|
|
537
|
+
const key = shared.getId();
|
|
542
538
|
components.set(key, {
|
|
543
|
-
id
|
|
539
|
+
id,
|
|
544
540
|
key,
|
|
545
541
|
kind: "function",
|
|
546
542
|
name,
|
|
@@ -587,10 +583,10 @@ function useComponentCollector(context, hint = DEFAULT_COMPONENT_HINT, options =
|
|
|
587
583
|
functionEntries.pop();
|
|
588
584
|
functionEntries.push({ ...entry, isComponent });
|
|
589
585
|
const initPath = AST8__namespace.getFunctionInitPath(entry.node);
|
|
590
|
-
const
|
|
591
|
-
const name = getComponentNameFromIdentifier(
|
|
586
|
+
const id = getFunctionComponentIdentifier(entry.node, context);
|
|
587
|
+
const name = getComponentNameFromIdentifier(id);
|
|
592
588
|
components.set(entry.key, {
|
|
593
|
-
id
|
|
589
|
+
id,
|
|
594
590
|
key: entry.key,
|
|
595
591
|
kind: "function",
|
|
596
592
|
name,
|
|
@@ -617,16 +613,16 @@ function useComponentCollectorLegacy() {
|
|
|
617
613
|
if (!isClassComponent(node)) {
|
|
618
614
|
return;
|
|
619
615
|
}
|
|
620
|
-
const
|
|
621
|
-
const key = getId();
|
|
616
|
+
const id = AST8__namespace.getClassIdentifier(node);
|
|
617
|
+
const key = shared.getId();
|
|
622
618
|
const flag = isPureComponent(node) ? ERClassComponentFlag.PureComponent : ERClassComponentFlag.None;
|
|
623
619
|
components.set(
|
|
624
620
|
key,
|
|
625
621
|
{
|
|
626
|
-
id
|
|
622
|
+
id,
|
|
627
623
|
key,
|
|
628
624
|
kind: "class",
|
|
629
|
-
name:
|
|
625
|
+
name: id?.name,
|
|
630
626
|
node,
|
|
631
627
|
// TODO: Get displayName of class component
|
|
632
628
|
displayName: eff._,
|
|
@@ -707,7 +703,6 @@ exports.RE_COMPONENT_NAME = RE_COMPONENT_NAME;
|
|
|
707
703
|
exports.RE_HOOK_NAME = RE_HOOK_NAME;
|
|
708
704
|
exports.getComponentNameFromIdentifier = getComponentNameFromIdentifier;
|
|
709
705
|
exports.getFunctionComponentIdentifier = getFunctionComponentIdentifier;
|
|
710
|
-
exports.getId = getId;
|
|
711
706
|
exports.hasNoneOrValidComponentName = hasNoneOrValidComponentName;
|
|
712
707
|
exports.isCallFromReact = isCallFromReact;
|
|
713
708
|
exports.isCallFromReactMember = isCallFromReactMember;
|
package/dist/index.mjs
CHANGED
|
@@ -1,16 +1,12 @@
|
|
|
1
1
|
import * as AST8 from '@eslint-react/ast';
|
|
2
2
|
import { flip, dual, _, returnFalse } from '@eslint-react/eff';
|
|
3
3
|
import * as JSX3 from '@eslint-react/jsx';
|
|
4
|
+
import { unsafeDecodeSettings, getId } from '@eslint-react/shared';
|
|
4
5
|
import { AST_NODE_TYPES } from '@typescript-eslint/types';
|
|
5
|
-
import { unsafeDecodeSettings } from '@eslint-react/shared';
|
|
6
6
|
import * as VAR from '@eslint-react/var';
|
|
7
7
|
import birecord from 'birecord';
|
|
8
8
|
|
|
9
9
|
// src/component/component-collector.ts
|
|
10
|
-
|
|
11
|
-
// src/utils/get-id.ts
|
|
12
|
-
var id = 0n;
|
|
13
|
-
var getId = () => (id++).toString();
|
|
14
10
|
function isInitializedFromReact(name, initialScope, importSource = "react") {
|
|
15
11
|
return name.toLowerCase() === "react" || VAR.isInitializedFromSource(
|
|
16
12
|
name,
|
|
@@ -144,8 +140,8 @@ function isReactHookName(name) {
|
|
|
144
140
|
// src/hook/is.ts
|
|
145
141
|
function isReactHook(node) {
|
|
146
142
|
if (node == null) return _;
|
|
147
|
-
const
|
|
148
|
-
return
|
|
143
|
+
const id = AST8.getFunctionIdentifier(node);
|
|
144
|
+
return id?.name != null && isReactHookName(id.name);
|
|
149
145
|
}
|
|
150
146
|
function isReactHookCall(node) {
|
|
151
147
|
if (node == null) return false;
|
|
@@ -240,13 +236,13 @@ function useHookCollector() {
|
|
|
240
236
|
const hooks = /* @__PURE__ */ new Map();
|
|
241
237
|
const fEntries = [];
|
|
242
238
|
const onFunctionEnter = (node) => {
|
|
243
|
-
const
|
|
244
|
-
const name =
|
|
239
|
+
const id = AST8.getFunctionIdentifier(node);
|
|
240
|
+
const name = id?.name;
|
|
245
241
|
if (name != null && isReactHookName(name)) {
|
|
246
242
|
const key = getId();
|
|
247
243
|
fEntries.push({ key, node });
|
|
248
244
|
hooks.set(key, {
|
|
249
|
-
id
|
|
245
|
+
id,
|
|
250
246
|
key,
|
|
251
247
|
kind: "function",
|
|
252
248
|
name,
|
|
@@ -415,9 +411,9 @@ function isComponentName(name) {
|
|
|
415
411
|
return RE_COMPONENT_NAME.test(name);
|
|
416
412
|
}
|
|
417
413
|
function hasNoneOrValidComponentName(node, context) {
|
|
418
|
-
const
|
|
419
|
-
if (
|
|
420
|
-
const name = Array.isArray(
|
|
414
|
+
const id = getFunctionComponentIdentifier(node, context);
|
|
415
|
+
if (id == null) return true;
|
|
416
|
+
const name = Array.isArray(id) ? id.at(-1)?.name : id.name;
|
|
421
417
|
return name != null && isComponentName(name);
|
|
422
418
|
}
|
|
423
419
|
|
|
@@ -509,11 +505,11 @@ function useComponentCollector(context, hint = DEFAULT_COMPONENT_HINT, options =
|
|
|
509
505
|
return;
|
|
510
506
|
}
|
|
511
507
|
const initPath = AST8.getFunctionInitPath(entry.node);
|
|
512
|
-
const
|
|
513
|
-
const name = getComponentNameFromIdentifier(
|
|
508
|
+
const id = getFunctionComponentIdentifier(entry.node, context);
|
|
509
|
+
const name = getComponentNameFromIdentifier(id);
|
|
514
510
|
const key = getId();
|
|
515
511
|
components.set(key, {
|
|
516
|
-
id
|
|
512
|
+
id,
|
|
517
513
|
key,
|
|
518
514
|
kind: "function",
|
|
519
515
|
name,
|
|
@@ -560,10 +556,10 @@ function useComponentCollector(context, hint = DEFAULT_COMPONENT_HINT, options =
|
|
|
560
556
|
functionEntries.pop();
|
|
561
557
|
functionEntries.push({ ...entry, isComponent });
|
|
562
558
|
const initPath = AST8.getFunctionInitPath(entry.node);
|
|
563
|
-
const
|
|
564
|
-
const name = getComponentNameFromIdentifier(
|
|
559
|
+
const id = getFunctionComponentIdentifier(entry.node, context);
|
|
560
|
+
const name = getComponentNameFromIdentifier(id);
|
|
565
561
|
components.set(entry.key, {
|
|
566
|
-
id
|
|
562
|
+
id,
|
|
567
563
|
key: entry.key,
|
|
568
564
|
kind: "function",
|
|
569
565
|
name,
|
|
@@ -590,16 +586,16 @@ function useComponentCollectorLegacy() {
|
|
|
590
586
|
if (!isClassComponent(node)) {
|
|
591
587
|
return;
|
|
592
588
|
}
|
|
593
|
-
const
|
|
589
|
+
const id = AST8.getClassIdentifier(node);
|
|
594
590
|
const key = getId();
|
|
595
591
|
const flag = isPureComponent(node) ? ERClassComponentFlag.PureComponent : ERClassComponentFlag.None;
|
|
596
592
|
components.set(
|
|
597
593
|
key,
|
|
598
594
|
{
|
|
599
|
-
id
|
|
595
|
+
id,
|
|
600
596
|
key,
|
|
601
597
|
kind: "class",
|
|
602
|
-
name:
|
|
598
|
+
name: id?.name,
|
|
603
599
|
node,
|
|
604
600
|
// TODO: Get displayName of class component
|
|
605
601
|
displayName: _,
|
|
@@ -671,4 +667,4 @@ function isFunctionOfUseEffectCleanup(node) {
|
|
|
671
667
|
return nearFunction === nearFunctionOfReturn && isFunctionOfUseEffectSetup(nearFunction);
|
|
672
668
|
}
|
|
673
669
|
|
|
674
|
-
export { DEFAULT_COMPONENT_HINT, ERClassComponentFlag, ERComponentHint, ERFunctionComponentFlag, ERPhaseRelevance, RE_COMPONENT_NAME, RE_HOOK_NAME, getComponentNameFromIdentifier, getFunctionComponentIdentifier,
|
|
670
|
+
export { DEFAULT_COMPONENT_HINT, ERClassComponentFlag, ERComponentHint, ERFunctionComponentFlag, ERPhaseRelevance, RE_COMPONENT_NAME, RE_HOOK_NAME, getComponentNameFromIdentifier, getFunctionComponentIdentifier, hasNoneOrValidComponentName, isCallFromReact, isCallFromReactMember, isChildrenCount, isChildrenCountCall, isChildrenForEach, isChildrenForEachCall, isChildrenMap, isChildrenMapCall, isChildrenOfCreateElement, isChildrenOnly, isChildrenOnlyCall, isChildrenToArray, isChildrenToArrayCall, isClassComponent, isCloneElement, isCloneElementCall, isComponentDidCatch, isComponentDidMount, isComponentName, isComponentWillUnmount, isCreateContext, isCreateContextCall, isCreateElement, isCreateElementCall, isCreateRef, isCreateRefCall, isDeclaredInRenderPropLoose, isDirectValueOfRenderPropertyLoose, isForwardRef, isForwardRefCall, isFromReact, isFromReactMember, isFunctionOfComponentDidMount, isFunctionOfComponentWillUnmount, isFunctionOfRenderMethod, isFunctionOfUseEffectCleanup, isFunctionOfUseEffectSetup, isGetDerivedStateFromError, isGetDerivedStateFromProps, isInitializedFromReact, isInsideCreateElementProps, isInsideReactHook, isInsideRenderMethod, isInversePhase, isMemo, isMemoCall, isPureComponent, isReactAPICallWithName, isReactAPIWithName, isReactHook, isReactHookCall, isReactHookCallWithName, isReactHookCallWithNameAlias, isReactHookCallWithNameLoose, isReactHookName, isRenderFunctionLoose, isRenderMethodLike, isRenderPropLoose, isThisSetState, isUseCallbackCall, isUseContextCall, isUseDebugValueCall, isUseDeferredValueCall, isUseEffectCall, isUseEffectCallLoose, isUseIdCall, isUseImperativeHandleCall, isUseInsertionEffectCall, isUseLayoutEffectCall, isUseMemoCall, isUseReducerCall, isUseRefCall, isUseStateCall, isUseSyncExternalStoreCall, isUseTransitionCall, useComponentCollector, useComponentCollectorLegacy, useHookCollector };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eslint-react/core",
|
|
3
|
-
"version": "1.24.0-next.
|
|
3
|
+
"version": "1.24.0-next.13",
|
|
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": {
|
|
@@ -39,11 +39,11 @@
|
|
|
39
39
|
"@typescript-eslint/utils": "^8.20.0",
|
|
40
40
|
"birecord": "^0.1.1",
|
|
41
41
|
"ts-pattern": "^5.6.0",
|
|
42
|
-
"@eslint-react/ast": "1.24.0-next.
|
|
43
|
-
"@eslint-react/
|
|
44
|
-
"@eslint-react/
|
|
45
|
-
"@eslint-react/
|
|
46
|
-
"@eslint-react/
|
|
42
|
+
"@eslint-react/ast": "1.24.0-next.13",
|
|
43
|
+
"@eslint-react/jsx": "1.24.0-next.13",
|
|
44
|
+
"@eslint-react/shared": "1.24.0-next.13",
|
|
45
|
+
"@eslint-react/var": "1.24.0-next.13",
|
|
46
|
+
"@eslint-react/eff": "1.24.0-next.13"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
49
|
"tsup": "^8.3.5",
|