Module: Jammit::Routes
- Defined in:
- lib/jammit/routes.rb
Overview
Rails 2.x routing module. Rails 3.x routes are in rails/routes.rb.
Class Method Summary collapse
-
.draw(map) ⇒ Object
Jammit uses a single route in order to slow down Rails’ routing speed by the absolute minimum.
Class Method Details
.draw(map) ⇒ Object
10 11 12 13 14 15 16 17 18 19 |
# File 'lib/jammit/routes.rb', line 10 def self.draw(map) map.jammit "/#{Jammit.package_path}/:package.:extension", { :controller => 'jammit', :action => 'package', :requirements => { # A hack to allow extension to include "." :extension => /.+/ } } end |