eslint-plugin-function 0.0.31 → 0.0.32

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 +2 -3
  2. package/package.json +18 -18
package/dist/index.js CHANGED
@@ -10,7 +10,7 @@ import { AST_NODE_TYPES } from "@typescript-eslint/types";
10
10
 
11
11
  //#region package.json
12
12
  var name = "eslint-plugin-function";
13
- var version = "0.0.30";
13
+ var version = "0.0.32";
14
14
 
15
15
  //#endregion
16
16
  //#region src/utils/create-rule.ts
@@ -184,8 +184,7 @@ function create(context, [opts]) {
184
184
  onViolation(returnExpression, { variants: "nullish" });
185
185
  return;
186
186
  }
187
- const returnType = getConstrainedTypeAtLocation(services, returnExpression);
188
- const parts = [...getTypeVariants(unionConstituents(returnType))];
187
+ const parts = [...getTypeVariants(unionConstituents(getConstrainedTypeAtLocation(services, returnExpression)))];
189
188
  if (parts.every((part) => allowedVariants.some((allowed) => part === allowed))) return;
190
189
  onViolation(returnExpression, { variants: [...parts].map((part) => `'${part}'`).join(", ") });
191
190
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-plugin-function",
3
- "version": "0.0.31",
3
+ "version": "0.0.32",
4
4
  "private": false,
5
5
  "description": "(WIP) The ESLint plugin for function-related rules.",
6
6
  "license": "MIT",
@@ -18,39 +18,39 @@
18
18
  "package.json"
19
19
  ],
20
20
  "dependencies": {
21
- "@eslint-react/ast": "^2.0.2-beta.1",
22
- "@eslint-react/eff": "^2.0.2-beta.1",
23
- "@eslint-react/kit": "^2.0.2-beta.1",
24
- "@typescript-eslint/scope-manager": "^8.44.1",
25
- "@typescript-eslint/type-utils": "^8.44.1",
26
- "@typescript-eslint/types": "^8.44.1",
27
- "@typescript-eslint/utils": "^8.44.1",
21
+ "@eslint-react/ast": "^2.1.0-beta.5",
22
+ "@eslint-react/eff": "^2.1.0-beta.5",
23
+ "@eslint-react/kit": "^2.1.0-beta.5",
24
+ "@typescript-eslint/scope-manager": "^8.46.0",
25
+ "@typescript-eslint/type-utils": "^8.46.0",
26
+ "@typescript-eslint/types": "^8.46.0",
27
+ "@typescript-eslint/utils": "^8.46.0",
28
28
  "string-ts": "^2.2.1",
29
29
  "ts-pattern": "^5.8.0"
30
30
  },
31
31
  "devDependencies": {
32
- "@eslint/markdown": "^7.3.0",
32
+ "@eslint/markdown": "^7.4.0",
33
33
  "@tsconfig/node22": "^22.0.2",
34
34
  "@tsconfig/strictest": "^2.0.6",
35
- "@types/node": "^24.5.2",
36
- "@typescript-eslint/rule-tester": "^8.44.1",
35
+ "@types/node": "^24.7.1",
36
+ "@typescript-eslint/rule-tester": "^8.46.0",
37
37
  "dedent": "^1.7.0",
38
38
  "dprint": "^0.50.2",
39
- "eslint": "^9.36.0",
39
+ "eslint": "^9.37.0",
40
40
  "eslint-config-flat-gitignore": "^2.1.0",
41
41
  "eslint-plugin-vitest": "^0.5.4",
42
- "jiti": "^2.6.0",
43
- "publint": "^0.3.13",
42
+ "jiti": "^2.6.1",
43
+ "publint": "^0.3.14",
44
44
  "skott": "^0.35.6",
45
- "tsdown": "^0.15.5",
46
- "typescript-eslint": "^8.44.1",
45
+ "tsdown": "^0.15.6",
46
+ "typescript-eslint": "^8.46.0",
47
47
  "vitest": "^3.2.4",
48
48
  "@local/configs": "0.0.0"
49
49
  },
50
50
  "peerDependencies": {
51
- "eslint": "^9.36.0",
51
+ "eslint": "^9.37.0",
52
52
  "ts-api-utils": "^2.1.0",
53
- "typescript": "^5.9.2"
53
+ "typescript": "^5.9.3"
54
54
  },
55
55
  "engines": {
56
56
  "node": ">=20.10.0"