Bug on custom type inference? Maybe I'm doing something wrong.
Then if I:
The type on
endTime should be Date not anyI'm using drizzle-orm
0.28.5endTimeDateany0.28.5export const timez = customType<
{
data: Date;
driverData: string;
config: { precision?: number };
}
>({
dataType(config) {
const precision = typeof config?.precision !== 'undefined'
? ` (${config.precision})`
: '';
return `time${precision} with time zone`;
},
fromDriver(value: string): Date {
return new Date(value);
},
});endTime: timez("end_time"),
// I get from inference
type Type = {
endTime?: any;
}