UNPKG

typescript-runtime-schemas

Version:

A TypeScript schema generation tool that extracts Zod schemas from TypeScript source files with runtime validation support. Generate validation schemas directly from your existing TypeScript types with support for computed types and constraint-based valid

29 lines (28 loc) 837 B
export interface SchemaGenConfig { input?: string; output?: string; preserveStructure?: boolean; singleFile?: boolean; glob?: string | string[]; exclude?: string | string[]; includeSourceInfo?: boolean; format?: 'json' | 'yaml' | 'table'; outputDir?: string; type?: string; concurrency?: number; noParallel?: boolean; chunkSize?: number; progress?: boolean; } /** * Load configuration from a file */ export declare function loadConfig(configPath: string): Promise<SchemaGenConfig>; /** * Find and load default config file */ export declare function findAndLoadConfig(startDir?: string): Promise<SchemaGenConfig | null>; /** * Merge configuration with command line options */ export declare function mergeConfig(config: SchemaGenConfig | null, options: any): SchemaGenConfig;