Open chenyukang opened 11 months ago
Hey! Great, this is exactly what I'd need, I'd be happy if this gets merged! Currently workaround would be to use #[schemars(description=...)]
as it doesn't do the same processing, but it'd be much nicer to continue writing the docs in the Rust doc strings.
#[schemars(description=...)]
is not a proper way for long description content.
For our project, we have a lot of very long documents in markdown: https://github.com/nervosnetwork/ckb/blob/develop/rpc/src/module/subscription.rs#L86-L171
my current PR is fixing the current strip
and merge
to avoid mess up format, maybe we should also add an option to don't do this kind of thing, keep good style is the responsibility of users.
The
strip
andmerge
operations inget_doc
andmerge_description_lines
will mess up code block format(or markdown format).This PR tries to avoid it in some scenarios.