Closed grocky closed 8 years ago
Hi @tjwebb, I realize this hook is going to be ported over to trails. It would be great to get this merged in if it looks ok to you.
Also, I'd be happy to help out on trailsjs/trailpack-swagger! I'd like to implement some parts of the spec that are missing in this project.
:+1:
@grocky feel free to get in touch with @konstantinzolotarev about the trailpack-swagger project: https://github.com/trailsjs/trailpack-swagger
You can also join our gitter: https://gitter.im/trailsjs/trails.
Thanks for the PR!
When models are singular (e.g.
User.js
) and routes are plural (e.g./users
) the definitions in the generated swagger document are not referenced in route responses.This uses the pluralize library to derive the singular case when needed.
This adds body parameters to the swagger document for POST and PUT requests.