Skip to content

Instantly share code, notes, and snippets.

@birula
Last active May 1, 2016 22:54
Show Gist options
  • Select an option

  • Save birula/01435e76c3562075f13ad0abf9f5488c to your computer and use it in GitHub Desktop.

Select an option

Save birula/01435e76c3562075f13ad0abf9f5488c to your computer and use it in GitHub Desktop.
mix phoenix.routes
➜ test mix phoenix.routes
page_path GET / Test.PageController :index
register_path POST /register Test.Addict.AddictController :register
register_path GET /register Test.Addict.AddictController :register
login_path POST /login Test.Addict.AddictController :login
login_path GET /login Test.Addict.AddictController :login
logout_path POST /logout Test.Addict.AddictController :logout
logout_path GET /logout Test.Addict.AddictController :logout
recover_password_path POST /recover_password Test.Addict.AddictController :recover_password
recover_password_path GET /recover_password Test.Addict.AddictController :recover_password
reset_password_path POST /reset_password Test.Addict.AddictController :reset_password
reset_password_path GET /reset_password Test.Addict.AddictController :reset_password
defmodule Test.Router do
use Test.Web, :router
use Addict.RoutesHelper
pipeline :browser do
plug :accepts, ["html"]
plug :fetch_session
plug :fetch_flash
plug :protect_from_forgery
plug :put_secure_browser_headers
end
pipeline :api do
plug :accepts, ["json"]
end
scope "/", Teste do
pipe_through :browser # Use the default browser stack
get "/", PageController, :index
addict :routes
end
# Other scopes may use custom stacks.
# scope "/api", Teste do
# pipe_through :api
# end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment