mirror of
https://github.com/metosin/reitit.git
synced 2025-12-18 08:51:12 +00:00
Update README.md
sample fits into mobile screen
This commit is contained in:
parent
095dfb6724
commit
9aefe5dea6
1 changed files with 2 additions and 2 deletions
|
|
@ -25,7 +25,7 @@ See [Issues](https://github.com/metosin/reitit/issues) for roadmap.
|
||||||
(def router
|
(def router
|
||||||
(r/router
|
(r/router
|
||||||
[["/api/ping" ::ping]
|
[["/api/ping" ::ping]
|
||||||
["/api/orders/:id" ::order-by-id]]))
|
["/api/orders/:id" ::order]]))
|
||||||
|
|
||||||
(r/match-by-path router "/api/ping")
|
(r/match-by-path router "/api/ping")
|
||||||
; #Match{:template "/api/ping"
|
; #Match{:template "/api/ping"
|
||||||
|
|
@ -34,7 +34,7 @@ See [Issues](https://github.com/metosin/reitit/issues) for roadmap.
|
||||||
; :params {}
|
; :params {}
|
||||||
; :path "/api/ping"}
|
; :path "/api/ping"}
|
||||||
|
|
||||||
(r/match-by-name router ::order-by-id {:id 2})
|
(r/match-by-name router ::order {:id 2})
|
||||||
; #Match{:template "/api/orders/:id",
|
; #Match{:template "/api/orders/:id",
|
||||||
; :meta {:name ::order-by-id},
|
; :meta {:name ::order-by-id},
|
||||||
; :result nil,
|
; :result nil,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue