Guest User

Untitled

a guest
May 20th, 2018
146
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. # Middleware routing anti-pattern
  2. use Jim::Rack, :bundled_uri => '/javascripts/bundled-live.js',
  3. :compressed_uri => '/javascripts/compressed-live.js'
  4.  
  5. use Rack::Coffee, {
  6. :urls => '/javascipts'
  7. }
  8.  
  9. use Sass::Plugin::Rack, :css_location => '/stylesheets'
  10.  
  11. use Rack::Sparklines, :prefix => '/sparks'
  12.  
  13.  
  14. # Use Rack's URLMap or another router of your choice
  15. map "/javascripts/bundle.js" do
  16. run Jim::Rack.new
  17. end
  18.  
  19. map "/javascripts/coffee.js" do
  20. run Rack::Coffee.new
  21. end
Add Comment
Please, Sign In to add comment