Has anyone setup hono with also a queue consumer?

Struggling to find an example on how to set that up, as the examples export the hono router as default. Anyone have an idea? 😅
1 Reply
Cyb3r-Jak3
Cyb3r-Jak3•2y ago
You would replace your export default with
export default {
fetch: app.fetch,
async queue(batch: MessageBatch<Error>, env: Environment) {
<your function here>
},
}
export default {
fetch: app.fetch,
async queue(batch: MessageBatch<Error>, env: Environment) {
<your function here>
},
}
Want results from more Discord servers?
Add your server