Mercurial
view benchmark/bun-http-framework-benchmark/src/node/elysia.js @ 216:e82b80b24012 default tip
[MrJuneJune] Make webp translate background job.
| author | June Park <parkjune1995@gmail.com> |
|---|---|
| date | Sat, 28 Feb 2026 21:04:43 -0800 |
| parents | a8976a008a9d |
| children |
line wrap: on
line source
const { Elysia } = require('elysia') const { node } = require('@elysiajs/node') const app = new Elysia({ adapter: node() }) .get('/', () => 'Hi') .get('/id/:id', (c) => { c.set.headers['x-powered-by'] = 'benchmark' return `${c.params.id} ${c.query.name}` }) .post('/json', (c) => c.body, { type: 'json' }) .listen(3000)