Urgent.News

What's breaking now, across thousands of outlets.

More in Tech

Nuxt server routes with Hono RPC-style type safety, no rewrite

Here is a Nuxt route written the way the docs recommend, and the code that calls it: // server/api/users/[id].get.ts import { z } from ' zod ' export default defineEventHandler ( async ( event ) => {…

  • Nuxt server routes now support Hono RPC-style type safety without code rewrite.
  • Developers define a single contract per route with validator, client types, and OpenAPI document.
  • Route path, method, and location unchanged; Nitro routing unaffected.

More from Wednesday 26 August →