@graphql-eslint/eslint-plugin 4.0.0-alpha-20230810160036-304c2c0 → 4.0.0-alpha.1
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +0 -2
- package/cjs/documents.d.ts +1 -1
- package/cjs/estree-converter/types.d.ts +1 -1
- package/cjs/flat-configs.d.ts +2 -2
- package/cjs/graphql-config.d.ts +1 -1
- package/cjs/graphql-config.js +1 -1
- package/cjs/index.d.ts +2 -4
- package/cjs/parser.d.ts +2 -2
- package/cjs/parser.js +2 -2
- package/cjs/processor.d.ts +1 -1
- package/cjs/rules/alphabetize.d.ts +4 -4
- package/cjs/rules/description-style.d.ts +3 -3
- package/cjs/rules/graphql-js-validation.d.ts +2 -2
- package/cjs/rules/index.d.ts +17 -19
- package/cjs/rules/index.js +1 -1
- package/cjs/rules/input-name.d.ts +3 -3
- package/cjs/rules/lone-executable-definition.d.ts +3 -3
- package/cjs/rules/match-document-filename.d.ts +3 -3
- package/cjs/rules/naming-convention.d.ts +3 -3
- package/cjs/rules/no-anonymous-operations.d.ts +2 -2
- package/cjs/rules/no-deprecated.d.ts +2 -2
- package/cjs/rules/no-duplicate-fields.d.ts +2 -2
- package/cjs/rules/no-hashtag-description.d.ts +2 -2
- package/cjs/rules/no-one-place-fragments.d.ts +2 -2
- package/cjs/rules/no-root-type.d.ts +3 -3
- package/cjs/rules/no-scalar-result-type-on-mutation.d.ts +2 -2
- package/cjs/rules/no-typename-prefix.d.ts +2 -2
- package/cjs/rules/no-unreachable-types.d.ts +2 -2
- package/cjs/rules/no-unreachable-types.js +1 -2
- package/cjs/rules/no-unused-fields.d.ts +2 -2
- package/cjs/rules/relay-arguments.d.ts +3 -3
- package/cjs/rules/relay-connection-types.d.ts +2 -2
- package/cjs/rules/relay-edge-types.d.ts +3 -3
- package/cjs/rules/relay-edge-types.js +1 -1
- package/cjs/rules/relay-page-info.d.ts +2 -2
- package/cjs/rules/require-deprecation-date.d.ts +3 -3
- package/cjs/rules/require-deprecation-reason.d.ts +2 -2
- package/cjs/rules/require-description.d.ts +3 -3
- package/cjs/rules/require-description.js +1 -1
- package/cjs/rules/require-field-of-type-query-in-mutation-result.d.ts +2 -2
- package/cjs/rules/require-import-fragment.d.ts +2 -2
- package/cjs/rules/require-import-fragment.js +4 -8
- package/cjs/rules/require-nullable-fields-with-oneof.d.ts +2 -2
- package/cjs/rules/require-nullable-result-in-root.d.ts +2 -2
- package/cjs/rules/require-selections.d.ts +3 -3
- package/cjs/rules/require-selections.js +1 -1
- package/cjs/rules/require-type-pattern-with-oneof.d.ts +2 -2
- package/cjs/rules/selection-set-depth.d.ts +3 -3
- package/cjs/rules/strict-id-in-types.d.ts +3 -3
- package/cjs/rules/unique-enum-value-names.d.ts +2 -2
- package/cjs/rules/unique-fragment-name.d.ts +1 -1
- package/cjs/rules/unique-operation-name.d.ts +2 -2
- package/cjs/schema.d.ts +1 -1
- package/cjs/siblings.d.ts +2 -2
- package/cjs/types.d.ts +4 -3
- package/cjs/utils.d.ts +3 -3
- package/esm/cache.js +1 -1
- package/esm/configs/index.js +1 -1
- package/esm/configs/operations-all.js +1 -1
- package/esm/configs/operations-recommended.js +1 -1
- package/esm/configs/schema-all.js +1 -1
- package/esm/configs/schema-recommended.js +1 -1
- package/esm/configs/schema-relay.js +1 -1
- package/esm/documents.d.mts +1 -1
- package/esm/documents.js +1 -1
- package/esm/estree-converter/converter.js +1 -1
- package/esm/estree-converter/types.d.mts +1 -1
- package/esm/estree-converter/utils.js +1 -1
- package/esm/flat-configs.d.mts +2 -2
- package/esm/flat-configs.js +1 -1
- package/esm/graphql-config.d.mts +1 -1
- package/esm/graphql-config.js +2 -2
- package/esm/index.d.mts +2 -4
- package/esm/index.js +1 -1
- package/esm/parser.d.mts +2 -2
- package/esm/parser.js +3 -3
- package/esm/processor.d.mts +1 -1
- package/esm/processor.js +1 -1
- package/esm/rules/alphabetize.d.mts +3 -3
- package/esm/rules/alphabetize.js +1 -1
- package/esm/rules/description-style.d.mts +3 -3
- package/esm/rules/description-style.js +1 -1
- package/esm/rules/graphql-js-validation.d.mts +2 -2
- package/esm/rules/graphql-js-validation.js +1 -1
- package/esm/rules/index.d.mts +17 -19
- package/esm/rules/index.js +2 -2
- package/esm/rules/input-name.d.mts +3 -3
- package/esm/rules/input-name.js +1 -1
- package/esm/rules/lone-executable-definition.d.mts +3 -3
- package/esm/rules/lone-executable-definition.js +1 -1
- package/esm/rules/match-document-filename.d.mts +3 -3
- package/esm/rules/match-document-filename.js +1 -1
- package/esm/rules/naming-convention.d.mts +3 -3
- package/esm/rules/naming-convention.js +1 -1
- package/esm/rules/no-anonymous-operations.d.mts +2 -2
- package/esm/rules/no-anonymous-operations.js +1 -1
- package/esm/rules/no-deprecated.d.mts +2 -2
- package/esm/rules/no-deprecated.js +1 -1
- package/esm/rules/no-duplicate-fields.d.mts +2 -2
- package/esm/rules/no-duplicate-fields.js +1 -1
- package/esm/rules/no-hashtag-description.d.mts +2 -2
- package/esm/rules/no-hashtag-description.js +1 -1
- package/esm/rules/no-one-place-fragments.d.mts +2 -2
- package/esm/rules/no-one-place-fragments.js +1 -1
- package/esm/rules/no-root-type.d.mts +3 -3
- package/esm/rules/no-root-type.js +1 -1
- package/esm/rules/no-scalar-result-type-on-mutation.d.mts +2 -2
- package/esm/rules/no-scalar-result-type-on-mutation.js +1 -1
- package/esm/rules/no-typename-prefix.d.mts +2 -2
- package/esm/rules/no-typename-prefix.js +1 -1
- package/esm/rules/no-unreachable-types.d.mts +2 -2
- package/esm/rules/no-unreachable-types.js +2 -3
- package/esm/rules/no-unused-fields.d.mts +2 -2
- package/esm/rules/no-unused-fields.js +1 -1
- package/esm/rules/relay-arguments.d.mts +3 -3
- package/esm/rules/relay-arguments.js +1 -1
- package/esm/rules/relay-connection-types.d.mts +2 -2
- package/esm/rules/relay-connection-types.js +1 -1
- package/esm/rules/relay-edge-types.d.mts +3 -3
- package/esm/rules/relay-edge-types.js +2 -2
- package/esm/rules/relay-page-info.d.mts +2 -2
- package/esm/rules/relay-page-info.js +1 -1
- package/esm/rules/require-deprecation-date.d.mts +3 -3
- package/esm/rules/require-deprecation-date.js +1 -1
- package/esm/rules/require-deprecation-reason.d.mts +2 -2
- package/esm/rules/require-deprecation-reason.js +1 -1
- package/esm/rules/require-description.d.mts +3 -3
- package/esm/rules/require-description.js +2 -2
- package/esm/rules/require-field-of-type-query-in-mutation-result.d.mts +2 -2
- package/esm/rules/require-field-of-type-query-in-mutation-result.js +1 -1
- package/esm/rules/require-import-fragment.d.mts +2 -2
- package/esm/rules/require-import-fragment.js +5 -9
- package/esm/rules/require-nullable-fields-with-oneof.d.mts +2 -2
- package/esm/rules/require-nullable-fields-with-oneof.js +1 -1
- package/esm/rules/require-nullable-result-in-root.d.mts +2 -2
- package/esm/rules/require-nullable-result-in-root.js +1 -1
- package/esm/rules/require-selections.d.mts +3 -3
- package/esm/rules/require-selections.js +2 -2
- package/esm/rules/require-type-pattern-with-oneof.d.mts +2 -2
- package/esm/rules/require-type-pattern-with-oneof.js +1 -1
- package/esm/rules/selection-set-depth.d.mts +3 -3
- package/esm/rules/selection-set-depth.js +1 -1
- package/esm/rules/strict-id-in-types.d.mts +3 -3
- package/esm/rules/strict-id-in-types.js +1 -1
- package/esm/rules/unique-enum-value-names.d.mts +2 -2
- package/esm/rules/unique-enum-value-names.js +1 -1
- package/esm/rules/unique-fragment-name.d.mts +1 -1
- package/esm/rules/unique-fragment-name.js +1 -1
- package/esm/rules/unique-operation-name.d.mts +2 -2
- package/esm/rules/unique-operation-name.js +1 -1
- package/esm/schema.d.mts +1 -1
- package/esm/schema.js +1 -1
- package/esm/siblings.d.mts +2 -2
- package/esm/siblings.js +1 -1
- package/esm/types.d.mts +4 -3
- package/esm/utils.d.mts +3 -3
- package/esm/utils.js +1 -1
- package/index.browser.mjs +721 -726
- package/package.json +5 -5
- /package/esm/{chunk-U3TKCM4X.js → chunk-UIAXBAMD.js} +0 -0
package/esm/rules/index.d.mts
CHANGED
@@ -1,24 +1,22 @@
|
|
1
1
|
import { RuleOptions } from './require-description.mjs';
|
2
2
|
import { CaseStyle } from '../utils.mjs';
|
3
|
-
import * as
|
3
|
+
import * as graphql from 'graphql';
|
4
4
|
import { GraphQLESLintRule } from '../types.mjs';
|
5
|
-
import * as json_schema_to_ts_lib_types_type_utils_writable_js from 'json-schema-to-ts/lib/types/type-utils/writable.js';
|
6
|
-
import 'graphql';
|
7
5
|
import 'eslint';
|
8
6
|
import 'estree';
|
7
|
+
import '../estree-converter/types.mjs';
|
9
8
|
import '../siblings.mjs';
|
10
9
|
import '@graphql-tools/utils';
|
11
|
-
import '../estree-converter/types.mjs';
|
12
|
-
import 'json-schema-to-ts';
|
13
10
|
import 'graphql-config';
|
11
|
+
import 'json-schema-to-ts';
|
14
12
|
|
15
13
|
declare const rules: {
|
16
14
|
alphabetize: GraphQLESLintRule<{
|
17
15
|
definitions?: boolean | undefined;
|
18
|
-
selections?:
|
19
|
-
arguments?:
|
16
|
+
selections?: ("OperationDefinition" | "FragmentDefinition")[] | undefined;
|
17
|
+
arguments?: ("Field" | "Directive" | "FieldDefinition" | "DirectiveDefinition")[] | undefined;
|
20
18
|
values?: boolean | undefined;
|
21
|
-
fields?:
|
19
|
+
fields?: ("ObjectTypeDefinition" | "InterfaceTypeDefinition" | "InputObjectTypeDefinition")[] | undefined;
|
22
20
|
variables?: boolean | undefined;
|
23
21
|
groups?: string[] | undefined;
|
24
22
|
}[]>;
|
@@ -32,26 +30,26 @@ declare const rules: {
|
|
32
30
|
checkMutations?: boolean | undefined;
|
33
31
|
}[]>;
|
34
32
|
'lone-executable-definition': GraphQLESLintRule<{
|
35
|
-
ignore?: ("fragment"
|
33
|
+
ignore?: (graphql.OperationTypeNode | "fragment")[] | undefined;
|
36
34
|
}[]>;
|
37
35
|
'match-document-filename': GraphQLESLintRule<{
|
38
|
-
fragment?:
|
39
|
-
style?:
|
36
|
+
fragment?: (CaseStyle | "matchDocumentStyle") | {
|
37
|
+
style?: (CaseStyle | "matchDocumentStyle") | undefined;
|
40
38
|
suffix?: string | undefined;
|
41
39
|
prefix?: string | undefined;
|
42
40
|
} | undefined;
|
43
|
-
mutation?:
|
44
|
-
style?:
|
41
|
+
mutation?: (CaseStyle | "matchDocumentStyle") | {
|
42
|
+
style?: (CaseStyle | "matchDocumentStyle") | undefined;
|
45
43
|
suffix?: string | undefined;
|
46
44
|
prefix?: string | undefined;
|
47
45
|
} | undefined;
|
48
|
-
subscription?:
|
49
|
-
style?:
|
46
|
+
subscription?: (CaseStyle | "matchDocumentStyle") | {
|
47
|
+
style?: (CaseStyle | "matchDocumentStyle") | undefined;
|
50
48
|
suffix?: string | undefined;
|
51
49
|
prefix?: string | undefined;
|
52
50
|
} | undefined;
|
53
|
-
query?:
|
54
|
-
style?:
|
51
|
+
query?: (CaseStyle | "matchDocumentStyle") | {
|
52
|
+
style?: (CaseStyle | "matchDocumentStyle") | undefined;
|
55
53
|
suffix?: string | undefined;
|
56
54
|
prefix?: string | undefined;
|
57
55
|
} | undefined;
|
@@ -59,8 +57,8 @@ declare const rules: {
|
|
59
57
|
}[]>;
|
60
58
|
'naming-convention': GraphQLESLintRule<{
|
61
59
|
[x: string]: unknown;
|
62
|
-
types?:
|
63
|
-
style?:
|
60
|
+
types?: ("camelCase" | "PascalCase" | "snake_case" | "UPPER_CASE") | {
|
61
|
+
style?: ("camelCase" | "PascalCase" | "snake_case" | "UPPER_CASE") | undefined;
|
64
62
|
suffix?: string | undefined;
|
65
63
|
prefix?: string | undefined;
|
66
64
|
forbiddenPrefixes?: string[] | undefined;
|
package/esm/rules/index.js
CHANGED
@@ -1,7 +1,7 @@
|
|
1
|
-
import "../chunk-
|
2
|
-
import { GRAPHQL_JS_VALIDATIONS } from "./graphql-js-validation.js";
|
1
|
+
import "../chunk-UIAXBAMD.js";
|
3
2
|
import { rule as alphabetize } from "./alphabetize.js";
|
4
3
|
import { rule as descriptionStyle } from "./description-style.js";
|
4
|
+
import { GRAPHQL_JS_VALIDATIONS } from "./graphql-js-validation.js";
|
5
5
|
import { rule as inputName } from "./input-name.js";
|
6
6
|
import { rule as loneExecutableDefinition } from "./lone-executable-definition.js";
|
7
7
|
import { rule as matchDocumentFilename } from "./match-document-filename.js";
|
@@ -3,10 +3,10 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
3
3
|
import 'eslint';
|
4
4
|
import 'estree';
|
5
5
|
import 'graphql';
|
6
|
+
import 'graphql-config';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const schema: {
|
12
12
|
readonly type: "array";
|
@@ -41,4 +41,4 @@ declare const schema: {
|
|
41
41
|
type RuleOptions = FromSchema<typeof schema>;
|
42
42
|
declare const rule: GraphQLESLintRule<RuleOptions>;
|
43
43
|
|
44
|
-
export { RuleOptions, rule };
|
44
|
+
export { type RuleOptions, rule };
|
package/esm/rules/input-name.js
CHANGED
@@ -3,10 +3,10 @@ import { FromSchema } from 'json-schema-to-ts';
|
|
3
3
|
import { GraphQLESLintRule } from '../types.mjs';
|
4
4
|
import 'eslint';
|
5
5
|
import 'estree';
|
6
|
+
import 'graphql-config';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const schema: {
|
12
12
|
readonly type: "array";
|
@@ -32,4 +32,4 @@ declare const schema: {
|
|
32
32
|
type RuleOptions = FromSchema<typeof schema>;
|
33
33
|
declare const rule: GraphQLESLintRule<RuleOptions>;
|
34
34
|
|
35
|
-
export { RuleOptions, rule };
|
35
|
+
export { type RuleOptions, rule };
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import "../chunk-
|
1
|
+
import "../chunk-UIAXBAMD.js";
|
2
2
|
import { OperationTypeNode } from "graphql";
|
3
3
|
import { ARRAY_DEFAULT_OPTIONS, getLocation, pascalCase } from "../utils.js";
|
4
4
|
const RULE_ID = "lone-executable-definition", definitionTypes = ["fragment", ...Object.values(OperationTypeNode)], schema = {
|
@@ -4,10 +4,10 @@ import { CaseStyle as CaseStyle$1 } from '../utils.mjs';
|
|
4
4
|
import 'eslint';
|
5
5
|
import 'estree';
|
6
6
|
import 'graphql';
|
7
|
+
import 'graphql-config';
|
8
|
+
import '../estree-converter/types.mjs';
|
7
9
|
import '../siblings.mjs';
|
8
10
|
import '@graphql-tools/utils';
|
9
|
-
import '../estree-converter/types.mjs';
|
10
|
-
import 'graphql-config';
|
11
11
|
|
12
12
|
type CaseStyle = CaseStyle$1 | 'matchDocumentStyle';
|
13
13
|
declare const schema: {
|
@@ -78,4 +78,4 @@ declare const schema: {
|
|
78
78
|
type RuleOptions = FromSchema<typeof schema>;
|
79
79
|
declare const rule: GraphQLESLintRule<RuleOptions>;
|
80
80
|
|
81
|
-
export { RuleOptions, rule };
|
81
|
+
export { type RuleOptions, rule };
|
@@ -3,10 +3,10 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
3
3
|
import 'eslint';
|
4
4
|
import 'estree';
|
5
5
|
import 'graphql';
|
6
|
+
import 'graphql-config';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
type AllowedStyle = 'camelCase' | 'PascalCase' | 'snake_case' | 'UPPER_CASE';
|
12
12
|
declare const schema: {
|
@@ -105,4 +105,4 @@ declare const schema: {
|
|
105
105
|
type RuleOptions = FromSchema<typeof schema>;
|
106
106
|
declare const rule: GraphQLESLintRule<RuleOptions>;
|
107
107
|
|
108
|
-
export { RuleOptions, rule };
|
108
|
+
export { type RuleOptions, rule };
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule;
|
12
12
|
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule<[], true>;
|
12
12
|
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule;
|
12
12
|
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const RULE_ID = "HASHTAG_COMMENT";
|
12
12
|
declare const rule: GraphQLESLintRule;
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule;
|
12
12
|
|
@@ -3,10 +3,10 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
3
3
|
import 'eslint';
|
4
4
|
import 'estree';
|
5
5
|
import 'graphql';
|
6
|
+
import 'graphql-config';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const schema: {
|
12
12
|
readonly type: "array";
|
@@ -31,4 +31,4 @@ declare const schema: {
|
|
31
31
|
type RuleOptions = FromSchema<typeof schema>;
|
32
32
|
declare const rule: GraphQLESLintRule<RuleOptions>;
|
33
33
|
|
34
|
-
export { RuleOptions, rule };
|
34
|
+
export { type RuleOptions, rule };
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule;
|
12
12
|
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule;
|
12
12
|
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule;
|
12
12
|
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import "../chunk-
|
1
|
+
import "../chunk-UIAXBAMD.js";
|
2
2
|
import {
|
3
3
|
DirectiveLocation,
|
4
4
|
isInterfaceType,
|
@@ -46,8 +46,7 @@ function getReachableTypes(schema) {
|
|
46
46
|
const { objects, interfaces } = schema.getImplementations(type);
|
47
47
|
for (const { astNode } of [...objects, ...interfaces])
|
48
48
|
visit(astNode, visitor);
|
49
|
-
} else
|
50
|
-
type?.astNode && visit(type.astNode, visitor);
|
49
|
+
} else type?.astNode && visit(type.astNode, visitor);
|
51
50
|
}, visitor = {
|
52
51
|
InterfaceTypeDefinition: collect,
|
53
52
|
ObjectTypeDefinition: collect,
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule;
|
12
12
|
|
@@ -3,10 +3,10 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
3
3
|
import 'eslint';
|
4
4
|
import 'estree';
|
5
5
|
import 'graphql';
|
6
|
+
import 'graphql-config';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const schema: {
|
12
12
|
readonly type: "array";
|
@@ -27,4 +27,4 @@ declare const schema: {
|
|
27
27
|
type RuleOptions = FromSchema<typeof schema>;
|
28
28
|
declare const rule: GraphQLESLintRule<RuleOptions, true>;
|
29
29
|
|
30
|
-
export { RuleOptions, rule };
|
30
|
+
export { type RuleOptions, rule };
|
@@ -2,11 +2,11 @@ import { Kind } from 'graphql';
|
|
2
2
|
import { GraphQLESLintRule } from '../types.mjs';
|
3
3
|
import 'eslint';
|
4
4
|
import 'estree';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const NON_OBJECT_TYPES: Kind[];
|
12
12
|
declare const rule: GraphQLESLintRule;
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import "../chunk-
|
1
|
+
import "../chunk-UIAXBAMD.js";
|
2
2
|
import { Kind } from "graphql";
|
3
3
|
const MUST_BE_OBJECT_TYPE = "MUST_BE_OBJECT_TYPE", MUST_CONTAIN_FIELD_EDGES = "MUST_CONTAIN_FIELD_EDGES", MUST_CONTAIN_FIELD_PAGE_INFO = "MUST_CONTAIN_FIELD_PAGE_INFO", MUST_HAVE_CONNECTION_SUFFIX = "MUST_HAVE_CONNECTION_SUFFIX", EDGES_FIELD_MUST_RETURN_LIST_TYPE = "EDGES_FIELD_MUST_RETURN_LIST_TYPE", PAGE_INFO_FIELD_MUST_RETURN_NON_NULL_TYPE = "PAGE_INFO_FIELD_MUST_RETURN_NON_NULL_TYPE", NON_OBJECT_TYPES = [
|
4
4
|
Kind.SCALAR_TYPE_DEFINITION,
|
@@ -3,10 +3,10 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
3
3
|
import 'eslint';
|
4
4
|
import 'estree';
|
5
5
|
import 'graphql';
|
6
|
+
import 'graphql-config';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const schema: {
|
12
12
|
readonly type: "array";
|
@@ -37,4 +37,4 @@ declare const schema: {
|
|
37
37
|
type RuleOptions = FromSchema<typeof schema>;
|
38
38
|
declare const rule: GraphQLESLintRule<RuleOptions, true>;
|
39
39
|
|
40
|
-
export { RuleOptions, rule };
|
40
|
+
export { type RuleOptions, rule };
|
@@ -1,11 +1,11 @@
|
|
1
|
-
import "../chunk-
|
2
|
-
import { getDocumentNodeFromSchema } from "@graphql-tools/utils";
|
1
|
+
import "../chunk-UIAXBAMD.js";
|
3
2
|
import {
|
4
3
|
isObjectType,
|
5
4
|
isScalarType,
|
6
5
|
Kind,
|
7
6
|
visit
|
8
7
|
} from "graphql";
|
8
|
+
import { getDocumentNodeFromSchema } from "@graphql-tools/utils";
|
9
9
|
import { getTypeName, requireGraphQLSchemaFromContext } from "../utils.js";
|
10
10
|
const RULE_ID = "relay-edge-types", MESSAGE_MUST_BE_OBJECT_TYPE = "MESSAGE_MUST_BE_OBJECT_TYPE", MESSAGE_MISSING_EDGE_SUFFIX = "MESSAGE_MISSING_EDGE_SUFFIX", MESSAGE_LIST_TYPE_ONLY_EDGE_TYPE = "MESSAGE_LIST_TYPE_ONLY_EDGE_TYPE", MESSAGE_SHOULD_IMPLEMENTS_NODE = "MESSAGE_SHOULD_IMPLEMENTS_NODE";
|
11
11
|
let edgeTypesCache;
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule;
|
12
12
|
|
@@ -3,10 +3,10 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
3
3
|
import 'eslint';
|
4
4
|
import 'estree';
|
5
5
|
import 'graphql';
|
6
|
+
import 'graphql-config';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const schema: {
|
12
12
|
readonly type: "array";
|
@@ -24,4 +24,4 @@ declare const schema: {
|
|
24
24
|
type RuleOptions = FromSchema<typeof schema>;
|
25
25
|
declare const rule: GraphQLESLintRule<RuleOptions>;
|
26
26
|
|
27
|
-
export { RuleOptions, rule };
|
27
|
+
export { type RuleOptions, rule };
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import "../chunk-
|
1
|
+
import "../chunk-UIAXBAMD.js";
|
2
2
|
import { valueFromNode } from "../estree-converter/index.js";
|
3
3
|
import { getNodeName } from "../utils.js";
|
4
4
|
const DATE_REGEX = /^\d{2}\/\d{2}\/\d{4}$/, MESSAGE_REQUIRE_DATE = "MESSAGE_REQUIRE_DATE", MESSAGE_INVALID_FORMAT = "MESSAGE_INVALID_FORMAT", MESSAGE_INVALID_DATE = "MESSAGE_INVALID_DATE", MESSAGE_CAN_BE_REMOVED = "MESSAGE_CAN_BE_REMOVED", schema = {
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule;
|
12
12
|
|
@@ -2,11 +2,11 @@ import { Kind } from 'graphql';
|
|
2
2
|
import { GraphQLESLintRule } from '../types.mjs';
|
3
3
|
import 'eslint';
|
4
4
|
import 'estree';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const RULE_ID = "require-description";
|
12
12
|
declare const ALLOWED_KINDS: readonly [Kind.OBJECT_TYPE_DEFINITION, Kind.INTERFACE_TYPE_DEFINITION, Kind.ENUM_TYPE_DEFINITION, Kind.SCALAR_TYPE_DEFINITION, Kind.INPUT_OBJECT_TYPE_DEFINITION, Kind.UNION_TYPE_DEFINITION, Kind.DIRECTIVE_DEFINITION, Kind.FIELD_DEFINITION, Kind.INPUT_VALUE_DEFINITION, Kind.ENUM_VALUE_DEFINITION, Kind.OPERATION_DEFINITION];
|
@@ -21,4 +21,4 @@ type RuleOptions = [
|
|
21
21
|
];
|
22
22
|
declare const rule: GraphQLESLintRule<RuleOptions>;
|
23
23
|
|
24
|
-
export { RULE_ID, RuleOptions, rule };
|
24
|
+
export { RULE_ID, type RuleOptions, rule };
|
@@ -1,6 +1,6 @@
|
|
1
|
-
import "../chunk-
|
2
|
-
import { getRootTypeNames } from "@graphql-tools/utils";
|
1
|
+
import "../chunk-UIAXBAMD.js";
|
3
2
|
import { Kind, TokenKind } from "graphql";
|
3
|
+
import { getRootTypeNames } from "@graphql-tools/utils";
|
4
4
|
import {
|
5
5
|
getLocation,
|
6
6
|
getNodeName,
|
@@ -2,11 +2,11 @@ import { GraphQLESLintRule } from '../types.mjs';
|
|
2
2
|
import 'eslint';
|
3
3
|
import 'estree';
|
4
4
|
import 'graphql';
|
5
|
+
import 'graphql-config';
|
5
6
|
import 'json-schema-to-ts';
|
7
|
+
import '../estree-converter/types.mjs';
|
6
8
|
import '../siblings.mjs';
|
7
9
|
import '@graphql-tools/utils';
|
8
|
-
import '../estree-converter/types.mjs';
|
9
|
-
import 'graphql-config';
|
10
10
|
|
11
11
|
declare const rule: GraphQLESLintRule;
|
12
12
|
|