Hcs.Router.Route
hcs · API reference
type 'a t = {
method_ : Method.t option;
path : string;
handler : 'a;
plugs : Pipeline.t;
}val make : ?method_:Method.t -> string -> 'a -> 'a tval get : string -> 'a -> 'a tval post : string -> 'a -> 'a tval put : string -> 'a -> 'a tval delete : string -> 'a -> 'a tval patch : string -> 'a -> 'a tval head : string -> 'a -> 'a tval options : string -> 'a -> 'a tval any : string -> 'a -> 'a tval plug :
((Server.request -> Server.response) -> Server.request -> Server.response) ->
'a t ->
'a tDeclarative route constructors and route-local plug attachment.