h3
Use the h3 utility when Zelavis should be mounted into an h3 application.
Basic usage
Section titled “Basic usage”import { H3, serve } from "h3";import { Zelavis } from "zelavis";import { nodeAdapter } from "zelavis/adapters/node";import { h3Handler } from "zelavis/h3";
const app = new H3();const zelavis = new Zelavis({ adapter: nodeAdapter() });
app.use("/**", h3Handler(zelavis));
serve(app, { port: 3000 });h3Handler(zelavis: Zelavis): h3 handlerGood fit
Section titled “Good fit”- h3-based apps and tooling
- Smaller Web-style servers that still want mounted middleware
- Setups where Zelavis should sit inside a broader h3 app