匹配整条路径的正确方法是什么?
(defroutes app
(ANY "*" [*]
{:status 200
:headers {"Content-Type" "text/plain"}
:body (str "path = " *)}))
有效,但它也给了我编译器警告WARNING: * should not be used as a route binding.
(defroutes app
(ANY "*" [path]
{:status 200
:headers {"Content-Type" "text/plain"}
:body (str "path = " path)}))
在没有警告的情况下进行编译,但不会将path
绑定到路径上。
答案 0 :(得分:0)
看起来像是
gdb
的工作原理。