File tree Expand file tree Collapse file tree 5 files changed +13
-8
lines changed
Expand file tree Collapse file tree 5 files changed +13
-8
lines changed Original file line number Diff line number Diff line change 11source "https://rubygems.org"
22
33gem "hanami" , "~> 2.3.0"
4- gem "hanami-router" , "~> 2.3.0"
4+ gem "hanami-controller" , "~> 2.3.0"
5+ gem "hanami-router" , "~> 2.3.0"
Original file line number Diff line number Diff line change 1+ require "hanami/action"
2+
3+ module Benchmark
4+ class Action < Hanami ::Action
5+ end
6+ end
Original file line number Diff line number Diff line change 11module Benchmark
22 module Actions
3- module Home
4- class Index < Benchmark ::Action
3+ module Index
4+ class Empty < Benchmark ::Action
55 def handle ( request , response )
66 response . body = ""
77 end
Original file line number Diff line number Diff line change 11module Benchmark
22 module Actions
3- module Home
4- class Index < Benchmark ::Action
3+ module User
4+ class Get < Benchmark ::Action
55 def handle ( request , response )
66 response . body = request . params [ :id ]
77 end
Original file line number Diff line number Diff line change 1- require "hanami/routes"
2-
31module Benchmark
42 class Routes < Hanami ::Routes
53 root to : "index.empty"
64
75 get "/user/:id" , to : "user.get"
86
9- post "/user" , to "index.empty"
7+ post "/user" , to : "index.empty"
108 end
119end
You can’t perform that action at this time.
0 commit comments