siyfion
05/21/2018, 11:27 AMactivityFeed field on a User, but I want it to return a type that doesn’t exist in the DB, built up of related data from various tables and logic..nilan
05/21/2018, 11:27 AMsiyfion
05/21/2018, 11:28 AMUser type from scratch?nilan
05/21/2018, 11:30 AMnilan
05/21/2018, 11:30 AMnilan
05/21/2018, 11:30 AMnilan
05/21/2018, 11:31 AMsiyfion
05/21/2018, 11:31 AMnilan
05/21/2018, 11:32 AMsiyfion
05/21/2018, 12:16 PMtype Experience is defined in both schemas, because in the Prisma-layer it has a host: User! field, but it’s removed in the API-layer.siyfion
05/21/2018, 12:17 PMreviews: [Review!]! isn’t defined in the API-layer…?siyfion
05/21/2018, 12:25 PMnilan
05/22/2018, 11:34 AMSo how does it know how to resolve that fieldyour resolver implementation 🙂
nilan
05/22/2018, 11:34 AMAlso, I can’t find an example of a field “addition”, only a removal.example: https://github.com/prismagraphql/graphql-server-example/blob/master/src/resolvers/Home.ts#L16
siyfion
05/22/2018, 12:11 PMreviews in the example app? There doesn’t seem to be one! So it does it get the one from the generated Prisma code?nilan
05/22/2018, 12:47 PMreviews field on the Experience typenilan
05/22/2018, 12:48 PMexperiences query from Prisma.siyfion
05/22/2018, 12:52 PMExperience type has been re-defined (not imported) in the API layer, but the resolvers for it don’t seem to have been. In my previous projects, just using Apollo, if a field returns an array of another type, I’d have to tell it how to retrieve that data...nilan
05/22/2018, 12:54 PMexperiences query in the application schema.nilan
05/22/2018, 12:54 PMtopExperiences query, for example.nilan
05/22/2018, 12:55 PMsiyfion
05/22/2018, 1:18 PMinfo parameter that’s passed through. So in effect when asking for the reviews field, you don’t need a resolver because the array and fields are all already there.nilan
05/22/2018, 1:28 PMnilan
05/22/2018, 1:29 PM