@graphql-tools/utils 7.3.0 → 7.5.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.
- package/es5/index.cjs.js +63 -25
- package/es5/index.cjs.js.map +1 -1
- package/es5/index.esm.js +57 -24
- package/es5/index.esm.js.map +1 -1
- package/es5/package.json +1 -1
- package/es5/print-schema-with-directives.d.ts +9 -4
- package/es5/types.d.ts +2 -1
- package/index.cjs.js +62 -25
- package/index.cjs.js.map +1 -1
- package/index.esm.js +56 -24
- package/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/print-schema-with-directives.d.ts +9 -4
- package/types.d.ts +2 -1
package/package.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { GraphQLSchema, GraphQLNamedType, DirectiveNode, InputValueDefinitionNode, GraphQLArgument, GraphQLDirective, DirectiveDefinitionNode, SchemaDefinitionNode, SchemaExtensionNode, GraphQLObjectType, ObjectTypeDefinitionNode, GraphQLField, GraphQLInterfaceType, InterfaceTypeDefinitionNode, UnionTypeDefinitionNode, GraphQLUnionType, GraphQLInputObjectType, InputObjectTypeDefinitionNode, GraphQLInputField, GraphQLEnumType, GraphQLEnumValue, EnumTypeDefinitionNode } from 'graphql';
|
|
2
|
-
import { PrintSchemaWithDirectivesOptions } from './types';
|
|
1
|
+
import { GraphQLSchema, GraphQLNamedType, DirectiveNode, FieldDefinitionNode, InputValueDefinitionNode, GraphQLArgument, EnumValueDefinitionNode, GraphQLDirective, DirectiveDefinitionNode, SchemaDefinitionNode, SchemaExtensionNode, GraphQLObjectType, ObjectTypeDefinitionNode, GraphQLField, GraphQLInterfaceType, InterfaceTypeDefinitionNode, UnionTypeDefinitionNode, GraphQLUnionType, GraphQLInputObjectType, InputObjectTypeDefinitionNode, GraphQLInputField, GraphQLEnumType, GraphQLEnumValue, EnumTypeDefinitionNode, GraphQLScalarType, ScalarTypeDefinitionNode, DocumentNode } from 'graphql';
|
|
2
|
+
import { GetDocumentNodeFromSchemaOptions, PrintSchemaWithDirectivesOptions } from './types';
|
|
3
|
+
export declare function getDocumentNodeFromSchema(schema: GraphQLSchema, options?: GetDocumentNodeFromSchemaOptions): DocumentNode;
|
|
3
4
|
export declare function printSchemaWithDirectives(schema: GraphQLSchema, options?: PrintSchemaWithDirectivesOptions): string;
|
|
4
5
|
export declare function astFromSchema(schema: GraphQLSchema, pathToDirectivesInExtensions: Array<string>): SchemaDefinitionNode | SchemaExtensionNode;
|
|
5
6
|
export declare function astFromDirective(directive: GraphQLDirective, schema: GraphQLSchema, pathToDirectivesInExtensions: Array<string>): DirectiveDefinitionNode;
|
|
@@ -11,6 +12,10 @@ export declare function astFromInterfaceType(type: GraphQLInterfaceType, schema:
|
|
|
11
12
|
export declare function astFromUnionType(type: GraphQLUnionType, schema: GraphQLSchema, pathToDirectivesInExtensions: Array<string>): UnionTypeDefinitionNode;
|
|
12
13
|
export declare function astFromInputObjectType(type: GraphQLInputObjectType, schema: GraphQLSchema, pathToDirectivesInExtensions: Array<string>): InputObjectTypeDefinitionNode;
|
|
13
14
|
export declare function astFromEnumType(type: GraphQLEnumType, schema: GraphQLSchema, pathToDirectivesInExtensions: Array<string>): EnumTypeDefinitionNode;
|
|
15
|
+
export declare function astFromScalarType(type: GraphQLScalarType, schema: GraphQLSchema, pathToDirectivesInExtensions: Array<string>): ScalarTypeDefinitionNode;
|
|
16
|
+
export declare function astFromField(field: GraphQLField<any, any>, schema: GraphQLSchema, pathToDirectivesInExtensions: Array<string>): FieldDefinitionNode;
|
|
17
|
+
export declare function astFromInputField(field: GraphQLInputField, schema: GraphQLSchema, pathToDirectivesInExtensions: Array<string>): InputValueDefinitionNode;
|
|
18
|
+
export declare function astFromEnumValue(value: GraphQLEnumValue, schema: GraphQLSchema, pathToDirectivesInExtensions: Array<string>): EnumValueDefinitionNode;
|
|
14
19
|
export declare function makeDeprecatedDirective(deprecationReason: string): DirectiveNode;
|
|
15
|
-
export declare function
|
|
16
|
-
export declare function
|
|
20
|
+
export declare function makeDirectiveNode(name: string, args: Record<string, any>, directive?: GraphQLDirective): DirectiveNode;
|
|
21
|
+
export declare function makeDirectiveNodes(schema: GraphQLSchema, directiveValues: Record<string, any>): Array<DirectiveNode>;
|
package/types.d.ts
CHANGED
|
@@ -10,9 +10,10 @@ export interface SchemaPrintOptions {
|
|
|
10
10
|
*/
|
|
11
11
|
commentDescriptions?: boolean;
|
|
12
12
|
}
|
|
13
|
-
export interface
|
|
13
|
+
export interface GetDocumentNodeFromSchemaOptions {
|
|
14
14
|
pathToDirectivesInExtensions?: Array<string>;
|
|
15
15
|
}
|
|
16
|
+
export declare type PrintSchemaWithDirectivesOptions = SchemaPrintOptions & GetDocumentNodeFromSchemaOptions;
|
|
16
17
|
export declare type Maybe<T> = null | undefined | T;
|
|
17
18
|
export declare type Constructor<T> = new (...args: any[]) => T;
|
|
18
19
|
/**
|