Module: Roda::RodaPlugins::BridgetownServer::RequestMethods

Defined in:
bridgetown-core/lib/roda/plugins/bridgetown_server.rb

Instance Method Summary collapse

Instance Method Details

#bridgetownObject

Starts up the Bridgetown routing system



142
143
144
# File 'bridgetown-core/lib/roda/plugins/bridgetown_server.rb', line 142

def bridgetown
  Bridgetown::Rack::Routes.start!(scope)
end

#cookiesObject

Monkeypatch Roda/Rack’s Request object so it returns a hash which allows for indifferent access



136
137
138
139
# File 'bridgetown-core/lib/roda/plugins/bridgetown_server.rb', line 136

def cookies
  # TODO: maybe replace with a simpler hash that offers an overloaded `[]` method
  _previous_roda_cookies.with_indifferent_access
end