Arthur Danjou 🧸
Arthur Danjou 🧸
Explore posts from servers
DTDrizzle Team
Created by Arthur Danjou 🧸 on 4/17/2024 in #help
Migration from prisma to Drizzle
Better than prisma
6 replies
DTDrizzle Team
Created by Arthur Danjou 🧸 on 4/17/2024 in #help
Migration from prisma to Drizzle
SImplified with drizzle
6 replies
DTDrizzle Team
Created by Arthur Danjou 🧸 on 4/17/2024 in #help
Migration from prisma to Drizzle
I found the solution :
const talents = await useDB().query.talents
.findMany({
orderBy: [asc(tables.talents.id)],
with: {
talentCategories: {
with: {
category: true,
},
},
},
})

return talents.filter(talent =>
(category === 'all' || talent.talentCategories.some(cat => cat.category.slug === category))
&& (favorite === 'false' || talent.favorite),
)
const talents = await useDB().query.talents
.findMany({
orderBy: [asc(tables.talents.id)],
with: {
talentCategories: {
with: {
category: true,
},
},
},
})

return talents.filter(talent =>
(category === 'all' || talent.talentCategories.some(cat => cat.category.slug === category))
&& (favorite === 'false' || talent.favorite),
)
`
6 replies
DTDrizzle Team
Created by Arthur Danjou 🧸 on 4/17/2024 in #help
Migration from prisma to Drizzle
I have to parameters : favorite and category. Favorite is a Boolean and category is a string (saved in db in the categories table). I want to fetch all the bookmarks of the selected category where the bookmarks are favorite or not (if favorite param is checked). And the category param can be ‘all’ so I want to fetch all the bookmarks favorite or not (depends again of the favorite param)
6 replies
NNuxt
Created by Arthur Danjou 🧸 on 3/29/2023 in #❓・help
Nuxt-TRPC with Prisma and supabase deployed to Vercel
If someone can help me 🙂
8 replies
NNuxt
Created by Arthur Danjou 🧸 on 3/29/2023 in #❓・help
Nuxt-TRPC with Prisma and supabase deployed to Vercel
the most recent
8 replies
NNuxt
Created by Arthur Danjou 🧸 on 3/29/2023 in #❓・help
Nuxt-TRPC with Prisma and supabase deployed to Vercel
I will try with this version. Actually, I use trpc-nuxt v0.8.0
8 replies
NNuxt
Created by Arthur Danjou 🧸 on 3/29/2023 in #❓・help
Nuxt-TRPC with Prisma and supabase deployed to Vercel
Hello, thank's for your response. It is a module that require to be imported as I do, as I read in the documentation
8 replies