So I am connecting Prisma orm to Graphql Nexus and need to convert graphql args that are T | null | undefined to T | undefined that is accepted by Prisma.
Here is how it is done inside Nexus https://github.com/graphql-nexus/nexus-plugin-prisma/blob/6c8801c6e1d99bfdb73a7c1c89db9607712b0e01/src/null.ts
How can this be adapted to my need?
You could do something like this
Update: I ended up publishing it to NPM. You can install it
npm install dnull