UNPKG

648 BTypeScriptView Raw
1import { ASTNode, GraphQLError, Source } from 'graphql';
2import { Maybe } from './types.js';
3interface GraphQLErrorOptions {
4 nodes?: ReadonlyArray<ASTNode> | ASTNode | null;
5 source?: Maybe<Source>;
6 positions?: Maybe<ReadonlyArray<number>>;
7 path?: Maybe<ReadonlyArray<string | number>>;
8 originalError?: Maybe<Error & {
9 readonly extensions?: unknown;
10 }>;
11 extensions?: any;
12}
13export declare function createGraphQLError(message: string, options?: GraphQLErrorOptions): GraphQLError;
14export declare function relocatedError(originalError: GraphQLError, path?: ReadonlyArray<string | number>): GraphQLError;
15export {};