Socket
Socket
Sign inDemoInstall

@graphql-tools/utils

Package Overview
Dependencies
Maintainers
3
Versions
1273
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@graphql-tools/utils - npm Package Compare versions

Comparing version 5.0.1-alpha-422d6a6.0 to 5.0.1-alpha-43368c2.0

toConfig.d.ts

8

filterSchema.d.ts

@@ -1,8 +0,8 @@

import { GraphQLType } from 'graphql';
import { GraphQLSchemaWithTransforms, RootFieldFilter } from './Interfaces';
import { GraphQLType, GraphQLSchema } from 'graphql';
import { RootFieldFilter } from './Interfaces';
export declare function filterSchema({ schema, rootFieldFilter, typeFilter, fieldFilter, }: {
schema: GraphQLSchemaWithTransforms;
schema: GraphQLSchema;
rootFieldFilter?: RootFieldFilter;
typeFilter?: (typeName: string, type: GraphQLType) => boolean;
fieldFilter?: (typeName: string, fieldName: string) => boolean;
}): GraphQLSchemaWithTransforms;
}): GraphQLSchema;

@@ -7,6 +7,4 @@ import { ASTNode } from 'graphql';

export declare function isValidPath(str: string): boolean;
export declare function resolveBuiltinModule<Module>(moduleName: string, option?: Module | string): Promise<Module>;
export declare function resolveBuiltinModuleSync<Module>(moduleName: string, option?: Module | string): Module;
export declare function compareStrings<A, B>(a: A, b: B): 0 | 1 | -1;
export declare function nodeToString(a: ASTNode): string;
export declare function compareNodes(a: ASTNode, b: ASTNode, customFn?: (a: any, b: any) => number): number;

@@ -45,1 +45,2 @@ export * from './loaders';

export * from './errors';
export * from './toConfig';

@@ -1,2 +0,2 @@

import { GraphQLSchema, GraphQLField, GraphQLInputType, GraphQLNamedType, GraphQLFieldResolver, GraphQLResolveInfo, GraphQLIsTypeOfFn, GraphQLTypeResolver, GraphQLScalarType, DocumentNode, FieldNode, GraphQLEnumValue, GraphQLEnumType, GraphQLUnionType, GraphQLArgument, GraphQLInputField, GraphQLInputObjectType, GraphQLInterfaceType, GraphQLObjectType, InlineFragmentNode, SelectionSetNode, GraphQLDirective, GraphQLFieldConfig, FragmentDefinitionNode, SelectionNode, VariableDefinitionNode, OperationDefinitionNode, GraphQLError, ExecutionResult as GraphQLExecutionResult, BuildSchemaOptions } from 'graphql';
import { GraphQLSchema, GraphQLField, GraphQLInputType, GraphQLNamedType, GraphQLFieldResolver, GraphQLResolveInfo, GraphQLIsTypeOfFn, GraphQLTypeResolver, GraphQLScalarType, DocumentNode, FieldNode, GraphQLEnumValue, GraphQLEnumType, GraphQLUnionType, GraphQLArgument, GraphQLInputField, GraphQLInputObjectType, GraphQLInterfaceType, GraphQLObjectType, InlineFragmentNode, SelectionSetNode, GraphQLDirective, GraphQLFieldConfig, FragmentDefinitionNode, SelectionNode, VariableDefinitionNode, OperationDefinitionNode, GraphQLError, ExecutionResult as GraphQLExecutionResult } from 'graphql';
import { SchemaVisitor } from './SchemaVisitor';

@@ -74,40 +74,2 @@ export interface ExecutionResult<TData = Record<string, any>> extends GraphQLExecutionResult {

};
export interface ExecutionParams<TArgs = Record<string, any>, TContext = any> {
document: DocumentNode;
variables?: TArgs;
context?: TContext;
info?: GraphQLResolveInfo;
}
export declare type AsyncExecutor = <TReturn = Record<string, any>, TArgs = Record<string, any>, TContext = Record<string, any>>(params: ExecutionParams<TArgs, TContext>) => Promise<ExecutionResult<TReturn>>;
export declare type SyncExecutor = <TReturn = Record<string, any>, TArgs = Record<string, any>, TContext = Record<string, any>>(params: ExecutionParams<TArgs, TContext>) => ExecutionResult<TReturn>;
export declare type Executor = AsyncExecutor | SyncExecutor;
export declare type Subscriber = <TReturn = Record<string, any>, TArgs = Record<string, any>, TContext = Record<string, any>>(params: ExecutionParams<TArgs, TContext>) => Promise<AsyncIterator<ExecutionResult<TReturn>> | ExecutionResult<TReturn>>;
export interface SubschemaConfig {
schema: GraphQLSchema;
rootValue?: Record<string, any>;
executor?: Executor;
subscriber?: Subscriber;
createProxyingResolver?: CreateProxyingResolverFn;
transforms?: Array<Transform>;
merge?: Record<string, MergedTypeConfig>;
}
export interface MergedTypeConfig {
selectionSet?: string;
fieldName?: string;
args?: (originalResult: any) => Record<string, any>;
resolve?: MergedTypeResolver;
}
export declare type MergedTypeResolver = (originalResult: any, context: Record<string, any>, info: GraphQLResolveInfo, subschema: GraphQLSchema | SubschemaConfig, selectionSet: SelectionSetNode) => any;
export interface GraphQLSchemaWithTransforms extends GraphQLSchema {
transforms?: Array<Transform>;
}
export interface IMakeRemoteExecutableSchemaOptions {
schema: GraphQLSchema | string;
executor?: Executor;
subscriber?: Subscriber;
createResolver?: (executor: Executor, subscriber: Subscriber) => GraphQLFieldResolver<any, any>;
buildSchemaOptions?: BuildSchemaOptions;
}
export declare type SchemaLikeObject = SubschemaConfig | GraphQLSchema | string | DocumentNode | Array<GraphQLNamedType>;
export declare function isSubschemaConfig(value: any): value is SubschemaConfig;
export interface ICreateRequest {

@@ -158,3 +120,2 @@ sourceSchema?: GraphQLSchema;

}
export declare type IndexedObject<V> = Record<string, V> | ReadonlyArray<V>;
export declare type VisitableSchemaType = GraphQLSchema | GraphQLObjectType | GraphQLInterfaceType | GraphQLInputObjectType | GraphQLNamedType | GraphQLScalarType | GraphQLField<any, any> | GraphQLInputField | GraphQLArgument | GraphQLUnionType | GraphQLEnumType | GraphQLEnumValue;

@@ -243,2 +204,1 @@ export declare type VisitorSelector = (type: VisitableSchemaType, methodName: string) => Array<SchemaVisitor | SchemaVisitorMap>;

export declare type DirectiveMapper = (directive: GraphQLDirective, schema: GraphQLSchema) => GraphQLDirective | null | undefined;
export declare type CreateProxyingResolverFn = (schema: GraphQLSchema | SubschemaConfig, transforms: Array<Transform>, operation: Operation, fieldName: string) => GraphQLFieldResolver<any, any>;
import { DocumentNode, GraphQLSchema, ParseOptions, BuildSchemaOptions } from 'graphql';
import { GraphQLSchemaValidationOptions } from 'graphql/type/schema';
export declare class Source {
export interface Source {
document?: DocumentNode;

@@ -8,7 +8,2 @@ schema?: GraphQLSchema;

location?: string;
constructor({ document, location, schema }: {
document?: DocumentNode;
location?: string;
schema?: GraphQLSchema;
});
}

@@ -15,0 +10,0 @@ export declare type SingleFileOptions = ParseOptions & GraphQLSchemaValidationOptions & BuildSchemaOptions & {

{
"name": "@graphql-tools/utils",
"version": "5.0.1-alpha-422d6a6.0",
"version": "5.0.1-alpha-43368c2.0",
"description": "Common package containting utils and types for GraphQL tools",

@@ -21,4 +21,5 @@ "peerDependencies": {

"devDependencies": {
"graphql-scalars": "1.1.2",
"iterall": "1.3.0"
"@types/dateformat": "3.0.1",
"dateformat": "3.0.3",
"graphql-scalars": "1.1.2"
},

@@ -25,0 +26,0 @@ "publishConfig": {

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc