Splitting Swagger object descriptions
sg-ad opened this issue · comments
Hi Robert,
This is a suggestion for enhancement. In addition to the definitions.adoc
that gets generated, I would like to generate individual files for each object (ex: person.adoc
, address.adoc
, purchase.adoc
...). I'd like to reference the model from a separate document that I've written, but I would like to include the object definitions individually in specific sections rather than in a single section. Do you think this would be something useful? I haven't dived into the code yet, but I'd be willing to take a stab at it. Do you think it would be something horribly difficult as the design stands, and would it be something possibly useful to others?
Thanks!
Sebastien
Hi,
I like the idea. But this feature would mean a refactoring, which breaks backwards compability.
But the project needs a refactoring anyway. Maybe its time for a new refactored Version.
Kind regards,
Robert
Hi Robert,
I went ahead and tried my hand at implementing a solution. I've created PR #19 so you can take a look and let me know what you think.
Thanks!
Sebastien
Hi Sebastien,
thank you very much. I like it when people show their own initiative an create PRs.
I will have a look at it.
Thx
Your PR looks good and it is a good temporary solution.
But Swagger2Markup definitely needs a refactoring, because the design is not flexible enough for further extensions. The design should be more composable.
I think I merge the PR, but will start refactoring soon.
If you like, you can join the Gitter channel:
https://gitter.im/RobWin/swagger2markup
I keep the issue open, until the PR is released
Thx for your contribution!
I referenced your PR in the Community contributions chapter
If you like Swagger2Markup, give it your GitHub Star :)