swajp
swajp
CCConvex Community
Created by swajp on 8/29/2024 in #support-community
how can i access the roomCode and redirect user
export const create = mutation({
handler: async ctx => {
const game = await ctx.db.insert("games", {
roomCode: generateRoomCode(),
round: 1,
currentWord: generateRandomWord()
})

return game
}
})
export const create = mutation({
handler: async ctx => {
const game = await ctx.db.insert("games", {
roomCode: generateRoomCode(),
round: 1,
currentWord: generateRandomWord()
})

return game
}
})
const onCreate = () => {
create().then(room => {
router.push(`/game/${room.roomCode}`)
})
}
const onCreate = () => {
create().then(room => {
router.push(`/game/${room.roomCode}`)
})
}
and i get Property 'roomCode' does not exist on type 'string & { __tableName: "games"; }'.ts(2339)
2 replies
CCConvex Community
Created by swajp on 7/27/2024 in #show-and-tell
Place to get new ideas by amazing creators
I heard a lot of people asking, "What projects should I build?", "What does a good portfolio look like?", etc. I decided to gather a lot of portfolios from people working at Vercel because they inspire me to never stop grinding! It can help you decide what your next project should be, or maybe you'll consider a design change for your portfolio. I am also gathering portfolios from people working at Meta and Apple, but it takes some time. You can help me with that by visiting the "Contribute" page. https://list.swajp.me/ I am open to feedback!
46 replies
CCConvex Community
Created by swajp on 1/15/2024 in #support-community
get name by id
No description
5 replies