Skip to main content

Module router

Module router 

Source
Expand description

A small, opinionated router.

  • Path segments starting with : are captured into req.param(name).
  • Middleware is a chain of async fn(Request, Next) -> Result<Response>.
  • 404 vs 405 is distinguished (path matched but method didn’t → 405).

Structs§

Next
Router

Type Aliases§

BoxFuture
HandlerFn
MiddlewareFn