4 ms·
as opposed to a self-running Sinatra handler which has to be quite significantly modified to be Rack-compatible Huh? Here's the `config.ru` that you need: $
by mattyb 15y ago
as opposed to a self-running Sinatra handler which has to be quite significantly modified to be Rack-compatible
Huh? Here's the `config.ru` that you need:
$: << File.dirname(__FILE__)
require 'app' #assuming app.rb
run Sinatra::Application
Note that I have no stake in the verbosity claims, as it's not something I particularly care about. But I wouldn't consider this a significant modification.
- masklinn 15y ago> Huh? Here's the `config.ru` that you need: Really? I remember it being significantly more work in the past, like having to change the `require` and create a class around all the routing methods If that's all which is required to make a Sinatra app into a good Rack citizen, then consider my previous assertion wrong and rescinded.