drizzle-zod insert/update schema refinements type
I usually want to apply same refinements to insert and update. To avoid duplication I want to define them in an object. How can I type it properly so that it knows the type of the schema arguments, etc.?
Tried unsuccessfully to extract from createInsertSchema() parameters, but I think it may be matching the first signature with a single generic , in which the second parameter is undefined:
Much appreciated!
0 Replies