【发布时间】:2015-12-14 12:30:01
【问题描述】:
如何列出处理函数上的所有路由?我正在寻找类似于 rails 的rake routes 的行为。例如:
(defroutes foo-routes
(GET "/foo/:foo-id"
[foo-id]
"bar response")
(GET "/bar/:bar-id"
[bar-id]
"foo response"))
是否可以从包含以下内容的 foo-bar-routes 中提取地图?
{:GET "/foo/:foo-id"
:GET "/bar/:bar-id"}
【问题讨论】: