网站首页
编程语言
数据库
系统相关
其他分享
编程问答
zodIssue
2024-11-19
[Typescript] Zod custom error message
constBookingSchema=z.object({roomType:z.string(),dueDate:z.string({message:"invalidduedate",}).date('dateformatiswrong'),numberOfGuests:z.number().min(1,"theremustbeatlea