I'm trying to write Sinatra in Rails style:
#in app.rb
get '/' do
# params request and response are accessible here
SomeController.new.some_method
end
I'm not able to access params, request or response in the controller:
class SomeController < Sinatra::Base
def some_method
#params are nil here
end
end
I can do it by passing as an argument from app.rb but I want it to behave like Rails.