UNPKG

@graphql-eslint/eslint-plugin

Version:
14 lines (13 loc) 999 B
import { AST } from 'eslint'; import { Comment, SourceLocation } from 'estree'; import { GraphQLNamedType, GraphQLOutputType, Location, Token } from 'graphql'; export declare const valueFromNode: (valueNode: import("graphql").ValueNode, variables?: import("graphql/jsutils/Maybe").Maybe<import("graphql/jsutils/ObjMap").ObjMap<unknown>>) => any; export declare function getBaseType(type: GraphQLOutputType): GraphQLNamedType; type TokenKindValue = ':' | '!' | '...' | '(' | ')' | '[' | ']' | '{' | '}' | '@' | '&' | '<SOF>' | '=' | '|' | '$' | 'BlockString' | 'Comment' | 'Float' | 'Int' | 'Name' | 'String'; export declare function convertToken<T extends TokenKindValue | 'Block' | 'Line'>(token: Token, type: T): Omit<AST.Token, 'type'> & { type: T; }; export declare function extractTokens(filePath: string, code: string): AST.Token[]; export declare function extractComments(loc?: Location): Comment[]; export declare function convertLocation(location: Location): SourceLocation; export {};