Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

28 lines (22 sloc) 0.503 kb
require "pakada"
require "pakada/dispatch"
require "awesome_print"
class ::MyModule
@path = Pathname.new(".")
include Pakada::Module
def routes
controller(:foo) {
action(:asdfg, :derp => "world") {
response.write "hello #{options[:derp]}!"
action(:bar).call
}
action(:bar) {
response.write "<br/>\n"
response.write params.inspect
}
}
route :test, "/(:action)", &controller(:foo)
end
end
Pakada.boot
run Pakada
Jump to Line
Something went wrong with that request. Please try again.