Pow v0.1.0-alpha.1 Pow.Extension.Phoenix.Router View Source

Handles extensions for the phonix router.

Usage

Configure lib/my_project_web/router.ex the following way:

defmodule MyAppWeb.Router do
  use Phoenix.Router
  use Pow.Phoenix.Router
  use Pow.Extension.Phoenix.Router,
    extensions: [PowExtensionOne, PowExtensionTwo]

  pipeline :browser do
    plug :accepts, ["html"]
    plug :fetch_session
    plug :fetch_flash
    plug :protect_from_forgery
    plug :put_secure_browser_headers
  end

  scope "/" do
    pipe_through :browser

    pow_routes()
    pow_extension_routes()
  end
end

Link to this section Summary

Link to this section Functions

Link to this function build_router_methods_module(module, config) View Source
build_router_methods_module(module(), Config.t()) ::
  {:module, module(), binary(), term()}
Link to this macro pow_extension_routes() View Source (macro)