Closed f0rr0 closed 1 year ago
A possible use case I have is that I am authoring a library in which the consumer can provide the type for a particular column in a table for example.
The example works if generic is removed:
const test = async () => {
// removed generic
const client = createPostgresClient<{ name: string }>({})
// works now
return await client.insertInto('sessions').values({ name: 'something' }).returningAll().executeTakeFirstOrThrow()
}
That's not possible I'm afraid.
Example: