juxt / yada

A powerful Clojure web library, full HTTP, full async - see https://juxt.pro/yada/index.html
MIT License
735 stars 97 forks source link

yada.swagger-parameters & yada.parameters are almost the same code. #315

Open boxxxie opened 4 years ago

boxxxie commented 4 years ago

i'm confused as to why the swagger one exists, and why it's the default param coercer in yada.

boxxxie commented 4 years ago

so, when i swap out yada.swagger-parameters with yada.parameters my backend just breaks. even with minimal schema (map of 1 key and 1 value, no custom types).

I think that it may be worth while to focus on 1 of these files, and get rid of the other. both files look like they have a bit of room for removing complexity, and adding flexibility/optimization.

like, with the swagger file, i can add multimethods for ring-swagger, and get coercers working without modifying the files, but my coercers are at the lowest priority. also there isn't a single default coercer map, there are 3 or 4 or 5 of them in different files.