Is your feature request related to a problem? Please describe.
Would be nice if documented object attributes also included a type annotation (if it exists)
Describe the solution you'd like
Given the following object
class Foo:
#: a bar attribute
bar: str
It should produce documentation like (not exact, just to get the idea across)
# Foo
## bar: `str`
a bar attribute
Describe alternatives you've considered
Repeating the type annotation in the doc comment. However this is suboptimal because I need to repeat myself and the comment + type annotation could get out of sync
Thanks for the suggestion; I've added a render_typehint_in_data_header option to the Markdown renderer. I've enabled it by default in the Hugo example, and this is what it looks like:
Is your feature request related to a problem? Please describe.
Would be nice if documented object attributes also included a type annotation (if it exists)
Describe the solution you'd like
Given the following object
It should produce documentation like (not exact, just to get the idea across)
Describe alternatives you've considered
Repeating the type annotation in the doc comment. However this is suboptimal because I need to repeat myself and the comment + type annotation could get out of sync
Additional context