Skip to content

Commit 59d1898

Browse files
committed
fix: update types
1 parent 41c9bcc commit 59d1898

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/lib/types.ts

+10
Original file line numberDiff line numberDiff line change
@@ -80,16 +80,26 @@ export type SupabaseClientOptions<SchemaName> = {
8080
accessToken?: () => Promise<string>
8181
}
8282

83+
export type GenericRelationship = {
84+
foreignKeyName: string
85+
columns: string[]
86+
isOneToOne?: boolean
87+
referencedRelation: string
88+
referencedColumns: string[]
89+
}
90+
8391
export type GenericTable = {
8492
Row: Record<string, unknown>
8593
Insert: Record<string, unknown>
8694
Update: Record<string, unknown>
95+
Relationships: GenericRelationship[]
8796
}
8897

8998
export type GenericUpdatableView = GenericTable
9099

91100
export type GenericNonUpdatableView = {
92101
Row: Record<string, unknown>
102+
Relationships: GenericRelationship[]
93103
}
94104

95105
export type GenericView = GenericUpdatableView | GenericNonUpdatableView

0 commit comments

Comments
 (0)