Skip to content
Source
Sign inSign up
TanStack/ai
Open History to see the last commit

table-schema.ts

13 lines449 Bytes

1import { z } from 'zod'
2​
3export const tableSchema = z.object({
4 title: z.string().meta({ description: 'Short title for the table' }),
5 rows: z.array(
6 z.object({
7 name: z.string().meta({ description: 'Row name' }),
8 year: z.number().meta({ description: 'First release year' }),
9 kind: z.string().meta({ description: 'Category or paradigm' }),
10 note: z.string().meta({ description: 'One-line typical use' }),
11 }),
12 ),
13})