Module: Roda::RodaPlugins::StaticRouting::RequestMethods

Defined in:
lib/roda/plugins/static_routing.rb

Instance Method Summary collapse

Instance Method Details

#static_route(&block) ⇒ Object

Assume that this request matches a static route, setting the remaining path to the emptry string and passing control to the given block.



124
125
126
127
128
129
130
# File 'lib/roda/plugins/static_routing.rb', line 124

def static_route(&block)
  @remaining_path = ''

  always do
    scope.instance_exec(self, &block)
  end
end