Get type for select query?

Hey guys, is there a way to infer the "select" type for a given table? for example:

async getUsers(selectColumns: ?) {
  return this.db.select(selectColumns).from(users)
}


I have a UsersService class with getUsers method. I want callers to be able to select specific columns.
Is is possible to achieve this type safety and autocomplete without directly using the drizzle client?
Was this page helpful?