I have an array of category IDs. How can
I have an array of category IDs. How can I retrieve all corresponding categories from the categories table?
5 Replies
const categories = await Promise.all(
categoryIds.map(async (id) => {
return await ctx.db.get("categories", id);
})
);
(much to my disappointment, db.get only takes one argument, so remove the "categories" first argument)
thx... it worked without first "categories" arg
petition to make it more abstract like this
actively working on it 🙂