types from nested relational queries

wondering what the type of user is?
async function getUserWithSettings(steamId: string): Promise<User> {
const user = await db.query.users.findFirst({
where: (user, { eq }) => eq(user.steamId, steamId),
with: {
settings: {
columns : {
steamId: false,
},
},
}
});
return user;
}
async function getUserWithSettings(steamId: string): Promise<User> {
const user = await db.query.users.findFirst({
where: (user, { eq }) => eq(user.steamId, steamId),
with: {
settings: {
columns : {
steamId: false,
},
},
}
});
return user;
}
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server