UNPKG

@ladislaogarcia/prisma-trpc-generator

Version:

Prisma 2+ generator to emit fully implemented tRPC routers

29 lines (28 loc) 1.32 kB
import { DMMF } from '@prisma/generator-helper'; import { z } from 'zod'; export declare const configSchema: z.ZodObject<{ withMiddleware: z.ZodDefault<z.ZodUnion<[z.ZodEffects<z.ZodEnum<["true", "false"]>, any, "true" | "false">, z.ZodDefault<z.ZodString>]>>; withShield: z.ZodDefault<z.ZodUnion<[z.ZodEffects<z.ZodEnum<["true", "false"]>, any, "true" | "false">, z.ZodDefault<z.ZodString>]>>; withZod: z.ZodDefault<z.ZodEffects<z.ZodEnum<["true", "false"]>, any, "true" | "false">>; contextPath: z.ZodDefault<z.ZodString>; trpcOptionsPath: z.ZodOptional<z.ZodString>; showModelNameInProcedure: z.ZodDefault<z.ZodEffects<z.ZodEnum<["true", "false"]>, any, "true" | "false">>; generateModelActions: z.ZodEffects<z.ZodDefault<z.ZodString>, DMMF.ModelAction[], string>; }, "strip", z.ZodTypeAny, { withMiddleware?: any; withShield?: any; withZod?: any; contextPath?: string; trpcOptionsPath?: string; showModelNameInProcedure?: any; generateModelActions?: DMMF.ModelAction[]; }, { withMiddleware?: string; withShield?: string; withZod?: "true" | "false"; contextPath?: string; trpcOptionsPath?: string; showModelNameInProcedure?: "true" | "false"; generateModelActions?: string; }>; export type Config = z.infer<typeof configSchema>;