This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
admin-panel/graphql-types/node_modules/graphql/utilities/coerceInputValue.d.ts

18 lines
401 B
TypeScript

import { GraphQLInputType } from '../type/definition';
import { GraphQLError } from '../error/GraphQLError';
type OnErrorCB = (
path: ReadonlyArray<string | number>,
invalidValue: any,
error: GraphQLError,
) => void;
/**
* Coerces a JavaScript value given a GraphQL Input Type.
*/
export function coerceInputValue(
inputValue: any,
type: GraphQLInputType,
onError?: OnErrorCB,
): any;