Tiny_httpd_server.RouteBasic type-safe routing.
val int : (int -> 'a, 'a) compMatches an integer.
val string : (string -> 'a, 'a) compMatches a string not containing '/' and binds it as is.
val string_urlencoded : (string -> 'a, 'a) compMatches a URL-encoded string, and decodes it.
val exact : string -> ('a, 'a) compexact "s" matches "s" and nothing else.
val return : ('a, 'a) tMatches the empty path.
val rest_of_path : (string -> 'a, 'a) tMatches a string, even containing '/'. This will match the entirety of the remaining route.
val rest_of_path_urlencoded : (string -> 'a, 'a) tMatches a string, even containing '/', an URL-decode it. This will match the entirety of the remaining route.
comp / route matches "foo/bar/…" iff comp matches "foo", and route matches "bar/…".
exact_path "foo/bar/..." r is equivalent to exact "foo" @/ exact "bar" @/ ... @/ r
val pp : Stdlib.Format.formatter -> (_, _) t -> unitPrint the route.
val to_string : (_, _) t -> stringPrint the route.