eslint-plugin-react-web-api 5.9.4 → 5.10.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.
Files changed (2) hide show
  1. package/dist/index.js +3 -3
  2. package/package.json +7 -7
package/dist/index.js CHANGED
@@ -5,7 +5,7 @@ import { P, isMatching, match } from "ts-pattern";
5
5
  import { ESLintUtils } from "@typescript-eslint/utils";
6
6
  import { Check, Compare, Extract, Traverse, isOneOf } from "@eslint-react/ast";
7
7
  import "@eslint-react/eslint";
8
- import { isAssignmentTargetEqual, isValueEqual, resolve, resolveEnclosingAssignmentTarget } from "@eslint-react/var";
8
+ import { isAssignmentTargetEqual, isInitializedFromReactNative, isValueEqual, resolve, resolveEnclosingAssignmentTarget } from "@eslint-react/var";
9
9
  import { AST_NODE_TYPES } from "@typescript-eslint/types";
10
10
  import { getStaticValue } from "@typescript-eslint/utils/ast-utils";
11
11
 
@@ -28,7 +28,7 @@ var __exportAll = (all, no_symbols) => {
28
28
  //#endregion
29
29
  //#region package.json
30
30
  var name$1 = "eslint-plugin-react-web-api";
31
- var version = "5.9.4";
31
+ var version = "5.10.0";
32
32
 
33
33
  //#endregion
34
34
  //#region src/types/component-phase.ts
@@ -180,7 +180,7 @@ function create$5(context) {
180
180
  if (!ComponentPhaseRelevance.has(fKind)) return;
181
181
  const unwrappedCallee = Extract.unwrap(node.callee);
182
182
  match(getCallKind$5(node)).with("addEventListener", (callKind) => {
183
- if (unwrappedCallee.type === AST_NODE_TYPES.MemberExpression && unwrappedCallee.object.type === AST_NODE_TYPES.Identifier && core.isAPIFromReactNative(unwrappedCallee.object.name, context.sourceCode.getScope(node))) return;
183
+ if (unwrappedCallee.type === AST_NODE_TYPES.MemberExpression && unwrappedCallee.object.type === AST_NODE_TYPES.Identifier && isInitializedFromReactNative(unwrappedCallee.object.name, context.sourceCode.getScope(node))) return;
184
184
  const [type, listener, options] = node.arguments;
185
185
  if (type == null || listener == null) return;
186
186
  const opts = options == null ? defaultOptions : getOptions(context, options);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-plugin-react-web-api",
3
- "version": "5.9.4",
3
+ "version": "5.10.0",
4
4
  "description": "ESLint React's ESLint plugin for interacting with Web APIs",
5
5
  "keywords": [
6
6
  "react",
@@ -41,17 +41,17 @@
41
41
  "@typescript-eslint/utils": "^8.62.0",
42
42
  "birecord": "^0.1.1",
43
43
  "ts-pattern": "^5.9.0",
44
- "@eslint-react/ast": "5.9.4",
45
- "@eslint-react/core": "5.9.4",
46
- "@eslint-react/eslint": "5.9.4",
47
- "@eslint-react/shared": "5.9.4",
48
- "@eslint-react/var": "5.9.4"
44
+ "@eslint-react/core": "5.10.0",
45
+ "@eslint-react/ast": "5.10.0",
46
+ "@eslint-react/eslint": "5.10.0",
47
+ "@eslint-react/var": "5.10.0",
48
+ "@eslint-react/shared": "5.10.0"
49
49
  },
50
50
  "devDependencies": {
51
51
  "@types/react": "^19.2.17",
52
52
  "@types/react-dom": "^19.2.3",
53
53
  "dedent": "^1.7.2",
54
- "eslint": "^10.5.0",
54
+ "eslint": "^10.6.0",
55
55
  "tsdown": "^0.22.3",
56
56
  "typescript": "6.0.3",
57
57
  "@local/configs": "0.0.0",