Repository navigation
Define a Typescript type to get upsert args of a model #27959
Replies: 1 comment
|
You can extract the exact 1. Model-specific type (Direct)Every model in your schema generates a corresponding import { Prisma } from '@prisma/client';
export type UserUpsertArgs = Prisma.UserUpsertArgs;2. Using
|
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Question
There is a way to create generic Typescript Type to get upsert args of a model ?
In version 6.12 I have the working type:
But in version 6.14 it doesn't work.
Thanks !
How to reproduce (optional)
Expected behavior (optional)
No response
Information about Prisma Schema, Client Queries and Environment (optional)
// Add your schema.prisma// Add any relevant Prisma Client queries hereOS:
Database:
Node.js version:
Run
prisma -vto see your Prisma version and paste itAll reactions