neat routing visualizer trick

This commit is contained in:
Mark Moser 2017-01-12 19:03:05 -06:00
parent d75ba7ea56
commit 5c3691ebe0

View File

@ -1,4 +1,6 @@
# frozen_string_literal: true # frozen_string_literal: true
# Neat routing visualizer, in irb:
# File.open('routing.html', 'w+'){|f| f.write Rails.application.routes.router.visualizer }
Rails.application.routes.draw do Rails.application.routes.draw do
get "/styleguide", to: "application#styleguide", as: :styleguide get "/styleguide", to: "application#styleguide", as: :styleguide
get "/admin/styleguide", to: "application#styleguide" get "/admin/styleguide", to: "application#styleguide"