James Homer
04/15/2020, 5:12 PMDarryl
04/16/2020, 2:08 PMt.field('createProduct', {
...t.prismaType.createProduct,
resolve: async (
_,
{
data: {
// ...
}
},
ctx: Context
) => {
// ...
}
The spreading of t.prismaType.createProduct gave me the inputs I required.
For the non-input types, I just used this: https://github.com/AhmedElywa/create-nexus-type#readmeJames Homer
04/16/2020, 6:44 PMJames Homer
04/16/2020, 6:48 PMt.prismaType thing is gone now so I used the arg() helper. Nexus then complained about missing types but I found that by exposing the default crud operation that error went away and I overrode the default name of the mutationDarryl
04/16/2020, 8:22 PMDarryl
04/17/2020, 8:04 AM…t.prismaType.createProduct to get all args from an auto-generated CRUD operation and the answer was just because it doesn’t work now and they don’t have a better solution yet.