package middleware

  1. Overview
  2. Docs

Minimal monad definition required by a Middleware.

type 'a t
val map : ('a -> 'b) -> 'a t -> 'b t

map fn a applies fn to a, producing a 'b t.

val bind : 'a t -> ('a -> 'b t) -> 'b t

bind fn a sequentially composes a with fn, passing the result of the first action to fn.

val return : 'a -> 'a t

return a injects the value a into the monadic type.