This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-01-28
Channels
- # aleph (10)
- # announcements (1)
- # aws-lambda (1)
- # beginners (162)
- # calva (81)
- # chlorine-clover (2)
- # cider (18)
- # clj-kondo (2)
- # cljs-dev (1)
- # cljsrn (12)
- # clojure (64)
- # clojure-australia (6)
- # clojure-europe (13)
- # clojure-nl (3)
- # clojure-sweden (26)
- # clojure-uk (36)
- # clojurescript (45)
- # community-development (10)
- # conjure (16)
- # core-logic (4)
- # cursive (6)
- # datascript (1)
- # emacs (1)
- # events (2)
- # fulcro (87)
- # girouette (5)
- # honeysql (4)
- # hoplon (3)
- # hugsql (3)
- # leiningen (8)
- # malli (18)
- # off-topic (33)
- # pathom (14)
- # reitit (5)
- # remote-jobs (1)
- # reveal (1)
- # shadow-cljs (50)
- # sql (3)
- # startup-in-a-month (1)
- # vim (5)
- # xtdb (30)
Is there a way of converting malli definitions to swagger 3 format?
Not sure about Swagger 3, malli.swagger
might be do Swagger 2, but not sure if there is difference in this level. It is just JSON Schema with a few extensions.
I've been reading the swagger specification and it's massive
The most obvious difference is that in JSON Schema and Swagger 2, there is a "definitions" key for common objects, whereas this doesn't exist in OpenAPI 3
I think it's replaced by the components object, or the schemas property on the components object
With currently implementation, Malli only handles the schema -> properties part. Reitit/Ring-swagger/Compojure-api does the higher level Swagger2 generation.
The properties part (JSON Schema) probably doesn't change much if at all between Swagger2 / OpenAPI 3.
do you know if there are plans to support OpenAPI 3 in reitit?
ah yeah, there's an open issue https://github.com/metosin/reitit/issues/84
Just chatted with @juhoteperi on Metosin internal about that. should be, not atm. should be a thin layer on top of malli.json-schema
.
haha great timing
ah oh you mean you chatted with him after my comment 🙂
I could have a look at it I guess, but swagger and malli are both completely new to me
Just = yesterday. https://github.com/metosin/malli/pull/354
Not sure about Swagger 3, malli.swagger
might be do Swagger 2, but not sure if there is difference in this level. It is just JSON Schema with a few extensions.