开发者

Does anyone have a Rake task to find the routes generated by Sinatra?

Does anyone have a Rake task to find the routes generated by Si开发者_如何学JAVAnatra?


Take a look at Sinatra::Base.routes. With those information you can easily generate the rake-task.

Update: There's a sinatra-rake-routes gem you could check.


Sinatra doesn't generate routes like Rails does. You need to define them yourself:

http://www.sinatrarb.com/intro#Routes

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜