Swoosh v0.23.2 Plug.Swoosh.MailboxPreview View Source
Plug that serves pages useful for previewing emails in development.
It takes one option at initialization:
base_path
- sets the base URL path where this module is plugged. Defaults to/
.
Examples
# in a Phoenix router
defmodule Sample.Router do
scope "/dev" do
pipe_through [:browser]
forward "/mailbox", Plug.Swoosh.MailboxPreview, [base_path: "/dev/mailbox"]
end
end
Link to this section Summary
Link to this section Functions
Link to this function
call(conn, opts) View Source
Callback implementation for Plug.call/2
.
Link to this function
init(opts) View Source
Callback implementation for Plug.init/1
.