import * as Types from '../types.d' ; import { gql } from '@apollo/client' ; import * as Apollo from '@apollo/client' ; const defaultOptions = { } as const ; export type HeroAndFriendsNamesQueryVariables = Types . Exact < { episode ? : Types . InputMaybe < Types . Episode > ; } > ; export type HeroAndFriendsNamesQuery = { __typename ? : 'Query' ; hero ? : { __typename ? : 'Droid' ; name : string ; friends ? : Array < { __typename ? : 'Droid' ; name : string ; } | { __typename ? : 'Human' ; name : string ; } | null | undefined > | null | undefined ; } | { __typename ? : 'Human' ; name : string ; friends ? : Array < { __typename ? : 'Droid' ; name : string ; } | { __typename ? : 'Human' ; name : string ; } | null | undefined > | null | undefined ; } | null | undefined ; } ; export const HeroAndFriendsNamesDocument = gql `
  query HeroAndFriendsNames($episode: Episode) {
    hero(episode: $episode) {
      name
      friends {
        name
      }
    }
  }
` ; param baseOptions example export function useHeroAndFriendsNamesQuery ( baseOptions ? ) { const options = { ... defaultOptions , ... baseOptions } ; return Apollo . useQuery < HeroAndFriendsNamesQuery , HeroAndFriendsNamesQueryVariables > ( HeroAndFriendsNamesDocument , options ) ; } export function useHeroAndFriendsNamesLazyQuery ( baseOptions ? ) { const options = { ... defaultOptions , ... baseOptions } ; return Apollo . useLazyQuery < HeroAndFriendsNamesQuery , HeroAndFriendsNamesQueryVariables > ( HeroAndFriendsNamesDocument , options ) ; } export type HeroAndFriendsNamesQueryHookResult = ReturnType < typeof useHeroAndFriendsNamesQuery > ; export type HeroAndFriendsNamesLazyQueryHookResult = ReturnType < typeof useHeroAndFriendsNamesLazyQuery > ; export type HeroAndFriendsNamesQueryResult = Apollo . QueryResult < HeroAndFriendsNamesQuery , HeroAndFriendsNamesQueryVariables > ;