hono-opinionated-guidelisted
Install: claude install-skill xonovex/platform
# Hono Opinionated Guidelines
An overlay on **hono-guide**. Apply **hono-guide** for all generic Hono work: application structure, validation/type safety, middleware patterns and combination, error handling, cookies, security, WebSockets, context storage, platform runtimes. This skill adds only the opinionated decisions on top.
## Requirements
- Hono ≥ 4.0, @hono/node-server, @hono/zod-openapi, TypeScript ≥ 5.8
## Opinionated patterns
- **Foundation** - Everything generic lives in **hono-guide**; this skill layers OpenAPI-first conventions on top
- **Async controllers** - Remove unnecessary `async` from synchronous handlers, see [references/controllers.md](references/controllers.md)
- **OpenAPIHono hierarchy** - Every router in the chain must be `OpenAPIHono`, see [references/openapi-router-hierarchy.md](references/openapi-router-hierarchy.md)
- **OpenAPI documentation** - Use `app.doc()` for automatic spec generation, see [references/openapi-spec-generation.md](references/openapi-spec-generation.md)
- **Router selection** - RegExpRouter for high-throughput persistent servers, see [references/router-selection.md](references/router-selection.md)
- **Request limits** - Use `bodyLimit` middleware to prevent DoS, see [references/body-limit.md](references/body-limit.md)
## Example
```typescript
import {OpenAPIHono} from "@hono/zod-openapi";
import {bodyLimit} from "hono/body-limit";
import {secureHeaders} from "hono/secure-headers";
export function createApp() {
const a