You still use standard library types and patterns, but with a simpler structure for routing, context, and middleware.
App
An app is the main entry point of a Mizu project. You can start with a single file or grow it into a larger application. Mizu does not force any layout or configuration style; it provides small, composable parts that scale with your needs.Routing
Routing defines how your app responds to different paths and methods. You write routes with plain Go functions, without annotations or generators. Everything stays explicit and easy to test, just like withnet/http.
Handler
A handler is a small Go function that returns an error. You write your logic directly, and Mizu handles errors or panics safely. This keeps your handlers short, clear, and predictable.Context
Each incoming request has aCtx, a small wrapper around http.ResponseWriter and *http.Request.
It provides helper methods for headers, responses, and logging, while still giving you access to the original Go objects.
Request
Reading input from a request is simple. You can get path parameters, query values, headers, form data, or JSON with clear, direct methods. There is no reflection, code generation, or hidden behavior.Response
Sending output works the same way. You can return plain text, JSON, HTML, or serve files directly throughCtx.
Everything follows Go’s HTTP design for consistency.
Static
Mizu can serve static files like images, CSS, or JavaScript from a folder or embedded data. It only takes one line to enable and needs no extra setup or plugins.Logging
Logging in Mizu uses Go’sslog package for structured logs.
It provides clean, consistent output for both development and production.
You can log from any handler or middleware.