eslint-plugin-react-hooks-extra 1.23.3-next.6 → 1.23.3-next.8

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 CHANGED
@@ -31,7 +31,7 @@ var VAR5__namespace = /*#__PURE__*/_interopNamespace(VAR5);
31
31
 
32
32
  // package.json
33
33
  var name = "eslint-plugin-react-hooks-extra";
34
- var version = "1.23.3-next.6";
34
+ var version = "1.23.3-next.8";
35
35
  var createRule = shared.createRuleForPlugin("hooks-extra");
36
36
  function isFromHookCall(name2, context, settings, predicate = eff.F.constTrue) {
37
37
  const hookAlias = settings.additionalHooks?.[name2] ?? [];
@@ -67,13 +67,7 @@ function isSetFunctionCall(context, settings) {
67
67
  if (!("name" in callee.object)) {
68
68
  return false;
69
69
  }
70
- const isAt = tsPattern.isMatching({
71
- type: types.AST_NODE_TYPES.MemberExpression,
72
- property: {
73
- type: types.AST_NODE_TYPES.Identifier,
74
- name: "at"
75
- }
76
- }, callee);
70
+ const isAt = callee.property.type === types.AST_NODE_TYPES.Identifier && callee.property.name === "at";
77
71
  const [index] = node.callee.arguments;
78
72
  if (!isAt || index == null) {
79
73
  return false;
package/dist/index.mjs CHANGED
@@ -4,11 +4,11 @@ import { O, F } from '@eslint-react/eff';
4
4
  import { createRuleForPlugin, getSettingsFromContext } from '@eslint-react/shared';
5
5
  import * as VAR5 from '@eslint-react/var';
6
6
  import { AST_NODE_TYPES } from '@typescript-eslint/types';
7
- import { match, isMatching } from 'ts-pattern';
7
+ import { match } from 'ts-pattern';
8
8
 
9
9
  // package.json
10
10
  var name = "eslint-plugin-react-hooks-extra";
11
- var version = "1.23.3-next.6";
11
+ var version = "1.23.3-next.8";
12
12
  var createRule = createRuleForPlugin("hooks-extra");
13
13
  function isFromHookCall(name2, context, settings, predicate = F.constTrue) {
14
14
  const hookAlias = settings.additionalHooks?.[name2] ?? [];
@@ -44,13 +44,7 @@ function isSetFunctionCall(context, settings) {
44
44
  if (!("name" in callee.object)) {
45
45
  return false;
46
46
  }
47
- const isAt = isMatching({
48
- type: AST_NODE_TYPES.MemberExpression,
49
- property: {
50
- type: AST_NODE_TYPES.Identifier,
51
- name: "at"
52
- }
53
- }, callee);
47
+ const isAt = callee.property.type === AST_NODE_TYPES.Identifier && callee.property.name === "at";
54
48
  const [index] = node.callee.arguments;
55
49
  if (!isAt || index == null) {
56
50
  return false;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-plugin-react-hooks-extra",
3
- "version": "1.23.3-next.6",
3
+ "version": "1.23.3-next.8",
4
4
  "description": "ESLint React's ESLint plugin for React Hooks related rules.",
5
5
  "keywords": [
6
6
  "react",
@@ -48,13 +48,13 @@
48
48
  "@typescript-eslint/utils": "^8.19.1",
49
49
  "string-ts": "^2.2.0",
50
50
  "ts-pattern": "^5.6.0",
51
- "@eslint-react/ast": "1.23.3-next.6",
52
- "@eslint-react/core": "1.23.3-next.6",
53
- "@eslint-react/eff": "1.23.3-next.6",
54
- "@eslint-react/shared": "1.23.3-next.6",
55
- "@eslint-react/types": "1.23.3-next.6",
56
- "@eslint-react/jsx": "1.23.3-next.6",
57
- "@eslint-react/var": "1.23.3-next.6"
51
+ "@eslint-react/ast": "1.23.3-next.8",
52
+ "@eslint-react/jsx": "1.23.3-next.8",
53
+ "@eslint-react/core": "1.23.3-next.8",
54
+ "@eslint-react/shared": "1.23.3-next.8",
55
+ "@eslint-react/types": "1.23.3-next.8",
56
+ "@eslint-react/var": "1.23.3-next.8",
57
+ "@eslint-react/eff": "1.23.3-next.8"
58
58
  },
59
59
  "devDependencies": {
60
60
  "@types/react": "^19.0.4",