mirror of
https://github.com/metosin/reitit.git
synced 2025-12-18 00:41:12 +00:00
Polish readme
This commit is contained in:
parent
1e2d1be09b
commit
70209aabce
1 changed files with 1 additions and 14 deletions
15
README.md
15
README.md
|
|
@ -70,8 +70,7 @@ A Ring routing app with input & output coercion using [data-specs](https://githu
|
|||
(ring/ring-handler
|
||||
(ring/router
|
||||
["/api"
|
||||
["/math" {:name ::math
|
||||
:get {:coercion reitit.coercion.spec/coercion
|
||||
["/math" {:get {:coercion reitit.coercion.spec/coercion
|
||||
:parameters {:query {:x int?, :y int?}}
|
||||
:responses {200 {:schema {:total pos-int?}}}
|
||||
:handler (fn [{{{:keys [x y]} :query} :parameters}]
|
||||
|
|
@ -113,18 +112,6 @@ Invalid request:
|
|||
|
||||
```
|
||||
|
||||
Reverse routing:
|
||||
|
||||
```clj
|
||||
(require '[reitit.core :as r])
|
||||
|
||||
(-> app
|
||||
(ring/get-router)
|
||||
(r/match-by-name ::math)
|
||||
:path)
|
||||
;; "/api/math"
|
||||
```
|
||||
|
||||
## More info
|
||||
|
||||
[Check out the full documentation!](https://metosin.github.io/reitit/)
|
||||
|
|
|
|||
Loading…
Reference in a new issue