import { Context } from './context'

/** Standard GraphQL resolver signature used across this API. */
export type ResolverFn<TArgs = Record<string, unknown>, TResult = unknown> = (
  parent: unknown,
  args: TArgs,
  context: Context,
  info?: unknown
) => TResult | Promise<TResult>

export type ResolverMap = {
  [key: string]: ResolverFn | ResolverMap | undefined
}
