Different from grape, middleware of maru is a standalone plug.
after callback within
middleware is just a plug with
defmodule Before do use Maru.Middleware def call(conn, _opts) do IO.puts "before request" conn end end defmodule API do use Maru.Router plug Before mount Router end
Updated less than a minute ago