Skip to content
On this page

z.string()

typescript

How to represent date/time types

Usage

Add to your sqldoc.config.ts:

typescript
export default {
  dialect: 'postgres',
  schema: ['./schema.sql'],
  codegen: [
    {
      template: 'zod',
      output: './generated/types.ts',
      config: {
        // See configuration options below
      },
    },
  ],
}

Then run:

bash
sqldoc codegen