MCPcopy Create free account
hub / github.com/ardatan/graphql-tools / parseInputValue

Function parseInputValue

packages/utils/src/transformInputValue.ts:68–76  ·  view source on GitHub ↗
(type: GraphQLInputType, value: any)

Source from the content-addressed store, hash-verified

66}
67
68export function parseInputValue(type: GraphQLInputType, value: any) {
69 return transformInputValue(type, value, (t, v) => {
70 try {
71 return t.parseValue(v);
72 } catch {
73 return v;
74 }
75 });
76}
77
78export function parseInputValueLiteral(type: GraphQLInputType, value: any) {
79 return transformInputValue(type, value, (t, v) => t.parseLiteral(v, {}));

Callers

nothing calls this directly

Calls 2

transformInputValueFunction · 0.85
parseValueMethod · 0.80

Tested by

no test coverage detected