Is it possible to use .map and batch?

const prepared = [1, 2, 3].map((id) => db.select().from(Users));

const batchDynamic = await db.batch(prepared); // TS Errors ❌
const batchStatic = await db.batch([db.select().from(Users)]); // Works ✅
const prepared = [1, 2, 3].map((id) => db.select().from(Users));

const batchDynamic = await db.batch(prepared); // TS Errors ❌
const batchStatic = await db.batch([db.select().from(Users)]); // Works ✅
1 Reply
Mario564
Mario5649h ago
@lordbinbash What exactly are those "TS Errors"?
Want results from more Discord servers?
Add your server