Hono
What Gigadrive Network detects for a Hono project, how a fetch export is served, and the defaults it applies.
Gigadrive Network detects Hono from a hono entry in the dependencies or devDependencies of your root package.json. The app becomes one Function that answers every path.
Hono support is experimental. The preset is a minimal Node server definition with nothing Hono-specific behind it, so check that your first deployment serves traffic before you rely on it.
Defaults
| Setting | Value |
|---|---|
| Runtime | node-22 |
| Memory | 128 MB |
| Max duration | 30 seconds |
| Route | /* to the resolved entrypoint |
| Environment | NODE_ENV=production |
| Build | your package.json build script |
Hono has the highest priority of the minimal server presets, ahead of Elysia, Fastify and Express.
The entrypoint
The preset starts from src/index.ts and then resolves the real file from your project: main in package.json first, then the file argument of a plain node, bun run, tsx or ts-node start script, then src/index.ts and the usual index, app and server candidates in both src/ and the project root.
The Node runtime executes JavaScript, so build TypeScript to JavaScript and point main at the output.
How your export is served
A Hono app exports a fetch handler, which is the first shape the Node runtime looks for:
import { Hono } from 'hono';
const app = new Hono();
app.get('/', (c) => c.text('Hello Hono'));
export default app;The runtime reads fetch (or per-method GET, POST, PUT, PATCH, DELETE, HEAD and OPTIONS exports) off the module or its default export, and binds it to the object it came from so Hono's instance methods keep their this. Each request arrives as a Web Request and your Response is returned as is.
A fetch export is a handler, not a server, so it cannot hold a socket: WebSocket upgrades to it are refused with 426 Upgrade Required. Start a real Node server instead, for example with @hono/node-server, and it is captured during import. WebSockets covers the rest.
Changing the defaults
version: 4
functions:
dist/index.js:
runtime: node-22
memory: 256
max_duration: 60A functions block replaces every entrypoint the preset produced, and settings you leave out fall back to the config file's defaults of memory: 128 and max_duration: 30.
Hono documents its own API at hono.dev.
