Running into an issue when I added `listing: forwa...
# orm-help
n
Running into an issue when I added
listing: forwardTo('db')
to my resolver. I get the following mesage:
Copy code
import { GraphQLServer } from 'graphql-yoga'
import { forwardTo} from 'prisma-binding'

import { Prisma } from './generated/prisma'
Copy code
Argument of type '{ typeDefs: string; resolvers: { Query: { listing: (parent: any, args: any, context: any, info: G...' is not assignable to parameter of type 'Props'.
  Types of property 'resolvers' are incompatible.
    Type '{ Query: { listing: (parent: any, args: any, context: any, info: GraphQLResolveInfo) => any; }; M...' is not assignable to type 'IResolvers'.
      Property 'Query' is incompatible with index signature.
        Type '{ listing: (parent: any, args: any, context: any, info: GraphQLResolveInfo) => any; }' is not assignable to type '(() => any) | IResolverObject | GraphQLScalarType'.
          Type '{ listing: (parent: any, args: any, context: any, info: GraphQLResolveInfo) => any; }' is not assignable to type 'GraphQLScalarType'.
            Property 'name' is missing in type '{ listing: (parent: any, args: any, context: any, info: GraphQLResolveInfo) => any; }'.
n
Ugh.
😞
m
I know its a annoying 🤒 Deploying to
now
works though, seems to be somehow workaroundable with some typescript config. Havent found the trick yet though 😞
n
I need to use it licalhost. Project deadline 😭
m
Just work around it 😉. Should take so much longer to pass on the resolvers, its just a little ugly
Copy code
group(parent, args, ctx: Context, info) {
    return ctx.db.query.group(args, info);
  },
n
Yeah I can do that 😭