UNPKG

@miragejs/graphql

Version:

A library for handling GraphQL requests with Mirage JS

16 lines (15 loc) 610 B
import type { GraphQLObjectType, GraphQLResolveInfo } from "graphql"; import type { QueryArgs, ResolverContext } from "../@types/index.js"; /** * Resolves a field that returns an object type. Since there are many different * object types, this function handles the different cases: * * * Objects * * Mutations * * Relay connections * * Relay edges * * Relay page info * * @see {@link https://graphql.org/learn/execution/#root-fields-resolvers} */ export default function resolveObject(source: any, args: QueryArgs, context: ResolverContext, info: GraphQLResolveInfo, type: GraphQLObjectType): any;