Skip to content

Commit 68934d5

Browse files
committed
fix: Pass down docstring style and options to pytkdocs
Issue-4: #4
1 parent 89592bd commit 68934d5

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

mkdocs.yml

-2
Original file line numberDiff line numberDiff line change
@@ -111,8 +111,6 @@ plugins:
111111
- https://mkdocstrings.github.io/pytkdocs/objects.inv
112112
paths: [src, docs]
113113
options:
114-
docstring_options:
115-
ignore_init_summary: true
116114
docstring_section_style: list
117115
filters: ["!^_"]
118116
group_by_category: true

src/mkdocstrings_handlers/python/handler.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ class PythonHandler(BaseHandler):
101101
102102
**Docstrings options:**
103103
104-
- `docstring_style` (`str`): The docstring style to use: `google`, `numpy`, `sphinx`, or `None`. Default: `"google"`.
104+
- `docstring_style` (`str`): The docstring style to use: `google`, `numpy`, `restructured-text`, or `None`. Default: `"google"`.
105105
- `docstring_options` (`dict`): The options for the docstring parser. See parsers under [`pytkdocs.parsers.docstrings`][].
106106
- `show_if_no_docstring` (`bool`): Show the object heading even if it has no docstring or children with docstrings. Default: `False`.
107107
@@ -251,7 +251,7 @@ def collect(self, identifier: str, config: MutableMapping[str, Any]) -> Collecto
251251
The collected object-tree.
252252
"""
253253
final_config = {}
254-
for option in ("filters", "members"):
254+
for option in ("filters", "members", "docstring_style", "docstring_options"):
255255
if option in config:
256256
final_config[option] = config[option]
257257
elif option in self.default_config:

0 commit comments

Comments
 (0)