This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-10-06
Channels
- # aleph (79)
- # bangalore-clj (3)
- # beginners (49)
- # boot (74)
- # cider (10)
- # cljs-dev (21)
- # cljsrn (2)
- # clojure (105)
- # clojure-berlin (1)
- # clojure-brasil (1)
- # clojure-dusseldorf (1)
- # clojure-korea (1)
- # clojure-poland (3)
- # clojure-russia (38)
- # clojure-spec (146)
- # clojure-uk (20)
- # clojurescript (70)
- # cloverage (1)
- # component (1)
- # core-async (23)
- # css (16)
- # cursive (22)
- # datascript (1)
- # datomic (22)
- # defnpodcast (6)
- # emacs (60)
- # events (1)
- # hoplon (94)
- # jobs (1)
- # jobs-rus (13)
- # luminus (11)
- # off-topic (11)
- # om (48)
- # onyx (5)
- # proton (7)
- # re-frame (87)
- # reagent (39)
- # rethinkdb (1)
- # ring-swagger (14)
- # rum (6)
- # specter (14)
- # untangled (105)
- # vim (6)
- # yada (22)
@sickill yes, you can attach extra data into Schemas via ring-swagger, there is an example of example 😉 in https://github.com/metosin/ring-swagger#example
so instead of :body-params [query :- String]
I do :body-params [query :- (rjs/field String {:example "blah blah"})]
?
hmm… I think the swagger-spec doesn’t have a example on individual fields at the moment, just for the schemas.
just re-browsed http://swagger.io/specification/, coudn’t find an example.
but, they work with map-schemas, so you can say: :body [body (rjs/field MyBodyMapSchema {:example {:a 1, :b 2}})]
If you find a way to do that with swagger, happy to patch ring-swagger to support it.