I've got some enums and structs which my program loads from a JSON file, and I'd like to provide some documentation on the format of this file for users. I've searched through the serde and serde_json documentation, looked for crates on crates.io, and I couldn't find a way to do this.
Does anyone know of a way to generate a markdown document for the format out of the doc
attributes on these types, variants and fields? Sort of like the way clap is able to generate documentation, and there are crates that can turn clap documentation into markdown, man page, etc.
If not, how about a crate that lets me programmatically extract the doc attributes from the types, and I could build this up myself? I'm sure that could be done with some proc-macros, so I'm hoping that someone else already has.
Right now, the best I can do is use rust-doc to generate a website for the API, but the audience are not (necessarily) rust programmers, and the JSON format ends up slightly different from the rust API.
Thanks for your help.