From 1188149407bea7348430d943c228e0ed6444b5ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vojt=C4=9Bch=20P=C3=A1rys?= Date: Sun, 5 Apr 2026 23:27:50 +0200 Subject: [PATCH] fix(generator): include nullable and relationKind in generated types.ts The generated types.ts had a hardcoded BindxSchemaEntityNames that was missing nullable and relationKind on relation field types. This caused TS errors because names.ts (generated by NameSchemaGenerator which has the correct type) includes these fields since 0.1.26. --- packages/bindx-generator/src/BindxGenerator.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/bindx-generator/src/BindxGenerator.ts b/packages/bindx-generator/src/BindxGenerator.ts index 0e16e6d..7e8ded2 100644 --- a/packages/bindx-generator/src/BindxGenerator.ts +++ b/packages/bindx-generator/src/BindxGenerator.ts @@ -108,8 +108,8 @@ export interface BindxSchemaEntityNames { readonly fields: { readonly [fieldName: string]: | { readonly type: 'column'; readonly columnType?: string; readonly enumName?: string } - | { readonly type: 'one'; readonly entity: string } - | { readonly type: 'many'; readonly entity: string } + | { readonly type: 'one'; readonly entity: string; readonly nullable?: boolean } + | { readonly type: 'many'; readonly entity: string; readonly relationKind?: 'oneHasMany' | 'manyHasMany'; readonly nullable?: boolean } } }