@graphql-eslint/eslint-plugin 4.0.0-alpha.4 → 4.0.0-alpha.5

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.
@@ -21,7 +21,7 @@ declare const rules: {
21
21
  groups?: string[] | undefined;
22
22
  }[]>;
23
23
  'description-style': GraphQLESLintRule<{
24
- style?: "block" | "inline" | undefined;
24
+ style: "block" | "inline";
25
25
  }[]>;
26
26
  'input-name': GraphQLESLintRule<{
27
27
  checkInputType?: boolean | undefined;
@@ -83,7 +83,7 @@ declare const rules: {
83
83
  'no-unreachable-types': GraphQLESLintRule;
84
84
  'no-unused-fields': GraphQLESLintRule;
85
85
  'relay-arguments': GraphQLESLintRule<{
86
- includeBoth?: boolean | undefined;
86
+ includeBoth: boolean;
87
87
  }[], true>;
88
88
  'relay-connection-types': GraphQLESLintRule;
89
89
  'relay-edge-types': GraphQLESLintRule<{
@@ -102,7 +102,7 @@ declare const rules: {
102
102
  'require-nullable-fields-with-oneof': GraphQLESLintRule;
103
103
  'require-nullable-result-in-root': GraphQLESLintRule;
104
104
  'require-selections': GraphQLESLintRule<{
105
- fieldName?: string | string[] | undefined;
105
+ fieldName: string | string[];
106
106
  }[], true>;
107
107
  'require-type-pattern-with-oneof': GraphQLESLintRule;
108
108
  'selection-set-depth': GraphQLESLintRule<{
@@ -38,7 +38,9 @@ declare const schema: {
38
38
  };
39
39
  };
40
40
  };
41
- type RuleOptions = FromSchema<typeof schema>;
41
+ type RuleOptions = FromSchema<typeof schema, {
42
+ keepDefaultedPropertiesOptional: true;
43
+ }>;
42
44
  declare const rule: GraphQLESLintRule<RuleOptions>;
43
45
 
44
46
  export { type RuleOptions, rule };
@@ -102,7 +102,9 @@ declare const schema: {
102
102
  readonly description: string;
103
103
  };
104
104
  };
105
- type RuleOptions = FromSchema<typeof schema>;
105
+ type RuleOptions = FromSchema<typeof schema, {
106
+ keepDefaultedPropertiesOptional: true;
107
+ }>;
106
108
  declare const rule: GraphQLESLintRule<RuleOptions>;
107
109
 
108
110
  export { type RuleOptions, rule };
@@ -34,7 +34,9 @@ declare const schema: {
34
34
  };
35
35
  };
36
36
  };
37
- type RuleOptions = FromSchema<typeof schema>;
37
+ type RuleOptions = FromSchema<typeof schema, {
38
+ keepDefaultedPropertiesOptional: true;
39
+ }>;
38
40
  declare const rule: GraphQLESLintRule<RuleOptions, true>;
39
41
 
40
42
  export { type RuleOptions, rule };
@@ -60,7 +60,9 @@ declare const schema: {
60
60
  };
61
61
  };
62
62
  };
63
- type RuleOptions = FromSchema<typeof schema>;
63
+ type RuleOptions = FromSchema<typeof schema, {
64
+ keepDefaultedPropertiesOptional: true;
65
+ }>;
64
66
  declare const rule: GraphQLESLintRule<RuleOptions>;
65
67
 
66
68
  export { type RuleOptions, rule };
@@ -21,7 +21,7 @@ declare const rules: {
21
21
  groups?: string[] | undefined;
22
22
  }[]>;
23
23
  'description-style': GraphQLESLintRule<{
24
- style?: "block" | "inline" | undefined;
24
+ style: "block" | "inline";
25
25
  }[]>;
26
26
  'input-name': GraphQLESLintRule<{
27
27
  checkInputType?: boolean | undefined;
@@ -83,7 +83,7 @@ declare const rules: {
83
83
  'no-unreachable-types': GraphQLESLintRule;
84
84
  'no-unused-fields': GraphQLESLintRule;
85
85
  'relay-arguments': GraphQLESLintRule<{
86
- includeBoth?: boolean | undefined;
86
+ includeBoth: boolean;
87
87
  }[], true>;
88
88
  'relay-connection-types': GraphQLESLintRule;
89
89
  'relay-edge-types': GraphQLESLintRule<{
@@ -102,7 +102,7 @@ declare const rules: {
102
102
  'require-nullable-fields-with-oneof': GraphQLESLintRule;
103
103
  'require-nullable-result-in-root': GraphQLESLintRule;
104
104
  'require-selections': GraphQLESLintRule<{
105
- fieldName?: string | string[] | undefined;
105
+ fieldName: string | string[];
106
106
  }[], true>;
107
107
  'require-type-pattern-with-oneof': GraphQLESLintRule;
108
108
  'selection-set-depth': GraphQLESLintRule<{
@@ -38,7 +38,9 @@ declare const schema: {
38
38
  };
39
39
  };
40
40
  };
41
- type RuleOptions = FromSchema<typeof schema>;
41
+ type RuleOptions = FromSchema<typeof schema, {
42
+ keepDefaultedPropertiesOptional: true;
43
+ }>;
42
44
  declare const rule: GraphQLESLintRule<RuleOptions>;
43
45
 
44
46
  export { type RuleOptions, rule };
@@ -102,7 +102,9 @@ declare const schema: {
102
102
  readonly description: string;
103
103
  };
104
104
  };
105
- type RuleOptions = FromSchema<typeof schema>;
105
+ type RuleOptions = FromSchema<typeof schema, {
106
+ keepDefaultedPropertiesOptional: true;
107
+ }>;
106
108
  declare const rule: GraphQLESLintRule<RuleOptions>;
107
109
 
108
110
  export { type RuleOptions, rule };
@@ -34,7 +34,9 @@ declare const schema: {
34
34
  };
35
35
  };
36
36
  };
37
- type RuleOptions = FromSchema<typeof schema>;
37
+ type RuleOptions = FromSchema<typeof schema, {
38
+ keepDefaultedPropertiesOptional: true;
39
+ }>;
38
40
  declare const rule: GraphQLESLintRule<RuleOptions, true>;
39
41
 
40
42
  export { type RuleOptions, rule };
@@ -60,7 +60,9 @@ declare const schema: {
60
60
  };
61
61
  };
62
62
  };
63
- type RuleOptions = FromSchema<typeof schema>;
63
+ type RuleOptions = FromSchema<typeof schema, {
64
+ keepDefaultedPropertiesOptional: true;
65
+ }>;
64
66
  declare const rule: GraphQLESLintRule<RuleOptions>;
65
67
 
66
68
  export { type RuleOptions, rule };
package/index.browser.js CHANGED
@@ -390,7 +390,7 @@ function convertToESTree(node, schema15) {
390
390
  // package.json
391
391
  var package_default = {
392
392
  name: "@graphql-eslint/eslint-plugin",
393
- version: "4.0.0-alpha.4",
393
+ version: "4.0.0-alpha.5",
394
394
  type: "module",
395
395
  description: "GraphQL plugin for ESLint",
396
396
  repository: "https://github.com/B2o5T/graphql-eslint",
@@ -399,21 +399,16 @@ var package_default = {
399
399
  engines: {
400
400
  node: ">=18"
401
401
  },
402
- main: "dist/cjs/index.js",
403
402
  exports: {
404
403
  "./package.json": "./package.json",
405
404
  ".": {
406
405
  require: {
407
- types: "./dist/cjs/index.d.ts",
406
+ types: "./dist/cjs/index.d.cts",
408
407
  default: "./dist/cjs/index.js"
409
408
  },
410
409
  import: {
411
410
  types: "./dist/esm/index.d.ts",
412
411
  default: "./dist/esm/index.js"
413
- },
414
- default: {
415
- types: "./dist/esm/index.d.ts",
416
- default: "./dist/esm/index.js"
417
412
  }
418
413
  }
419
414
  },
@@ -446,13 +441,13 @@ var package_default = {
446
441
  devDependencies: {
447
442
  "@theguild/eslint-rule-tester": "workspace:*",
448
443
  "@types/debug": "4.1.12",
449
- "@types/eslint": "9.6.0",
450
- "@types/estree": "1.0.5",
444
+ "@types/eslint": "9.6.1",
445
+ "@types/estree": "1.0.6",
451
446
  "@types/graphql-depth-limit": "1.1.6",
452
447
  "@types/json-schema": "7.0.15",
453
448
  "@types/lodash.lowercase": "4.3.9",
454
449
  graphql: "16.9.0",
455
- "json-schema-to-ts": "2.12.0",
450
+ "json-schema-to-ts": "3.1.1",
456
451
  "vite-tsconfig-paths": "^5.0.0"
457
452
  },
458
453
  publishConfig: {
@@ -1939,7 +1934,7 @@ var RULE_ID2 = "lone-executable-definition", definitionTypes = ["fragment", ...O
1939
1934
  };
1940
1935
 
1941
1936
  // src/rules/match-document-filename.ts
1942
- import { basename, extname } from "path";
1937
+ import { basename, extname } from "node:path";
1943
1938
  import { Kind as Kind7 } from "graphql";
1944
1939
  var MATCH_EXTENSION = "MATCH_EXTENSION", MATCH_STYLE = "MATCH_STYLE", CASE_STYLES = [
1945
1940
  "camelCase",
@@ -2968,7 +2963,7 @@ var RULE_ID6 = "HASHTAG_COMMENT", rule10 = {
2968
2963
  };
2969
2964
 
2970
2965
  // src/rules/no-one-place-fragments.ts
2971
- import { relative } from "path";
2966
+ import { relative } from "node:path";
2972
2967
  import { visit as visit4 } from "graphql";
2973
2968
  var RULE_ID7 = "no-one-place-fragments", rule11 = {
2974
2969
  meta: {
@@ -4338,7 +4333,7 @@ var RULE_ID15 = "require-field-of-type-query-in-mutation-result", rule24 = {
4338
4333
  };
4339
4334
 
4340
4335
  // src/rules/require-import-fragment.ts
4341
- import path from "path";
4336
+ import path from "node:path";
4342
4337
  var RULE_ID16 = "require-import-fragment", SUGGESTION_ID = "add-import-expression", rule25 = {
4343
4338
  meta: {
4344
4339
  type: "suggestion",
@@ -5178,7 +5173,7 @@ var rule32 = {
5178
5173
  };
5179
5174
 
5180
5175
  // src/rules/unique-fragment-name.ts
5181
- import { relative as relative2 } from "path";
5176
+ import { relative as relative2 } from "node:path";
5182
5177
  import { Kind as Kind25 } from "graphql";
5183
5178
  var RULE_ID23 = "unique-fragment-name", checkNode = (context, node, ruleId) => {
5184
5179
  let documentName = node.name.value, siblings = requireSiblingsOperations(ruleId, context), siblingDocuments = node.kind === Kind25.FRAGMENT_DEFINITION ? siblings.getFragment(documentName) : siblings.getOperation(documentName), filepath = context.filename, conflictingDocuments = siblingDocuments.filter((f) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@graphql-eslint/eslint-plugin",
3
- "version": "4.0.0-alpha.4",
3
+ "version": "4.0.0-alpha.5",
4
4
  "type": "module",
5
5
  "description": "GraphQL plugin for ESLint",
6
6
  "repository": "https://github.com/B2o5T/graphql-eslint",
@@ -9,21 +9,16 @@
9
9
  "engines": {
10
10
  "node": ">=18"
11
11
  },
12
- "main": "cjs/index.js",
13
12
  "exports": {
14
13
  "./package.json": "./package.json",
15
14
  ".": {
16
15
  "require": {
17
- "types": "./cjs/index.d.ts",
16
+ "types": "./cjs/index.d.cts",
18
17
  "default": "./cjs/index.js"
19
18
  },
20
19
  "import": {
21
20
  "types": "./esm/index.d.ts",
22
21
  "default": "./esm/index.js"
23
- },
24
- "default": {
25
- "types": "./esm/index.d.ts",
26
- "default": "./esm/index.js"
27
22
  }
28
23
  }
29
24
  },