Files
the-biergarten-app/src/services/BeerComment/schema/BeerCommentQueryResult.ts
2023-04-11 23:32:06 -04:00

15 lines
345 B
TypeScript

import { z } from 'zod';
const BeerCommentQueryResult = z.object({
id: z.string().uuid(),
content: z.string().min(1).max(500),
rating: z.number().int().min(1).max(5),
createdAt: z.coerce.date(),
postedBy: z.object({
id: z.string().uuid(),
username: z.string().min(1).max(50),
}),
});
export default BeerCommentQueryResult;