-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Native directive params support #55
Comments
It seems the types are defined in https://pydoc.dev/sphinx/latest/sphinx.directives.ObjectDescription.html?private=1#doc_field_types here is docs for field: https://pydoc.dev/sphinx/latest/sphinx.util.docfields.Field.html?private=1, code: https://github.com/sphinx-doc/sphinx/blob/v5.3.0/sphinx/util/docfields.py |
I have no context on alternative parsers for sphinx, and won't be able to support them well. You'd need to submit a pull request with some form of regression tests in order to get support for this use case added. |
For classes I would also expect attributes like "extends", "implements", ex:
|
I am migrating sphinx docs from .rst to .md.
Rst file:
Md/MyST file:
Currently the output looks like:
Notice, the native MyST param is missing/ignored and the 2nd param not parsed [1]/formated. I think the problem is
sphinxcontrib-phpdomain
extension tries to parse the params from rst text directly instead of supporting directive/AST params directly.[1] MyST spec https://myst-parser.readthedocs.io/en/latest/syntax/roles-and-directives.html#parameterizing-directive - directives are parsed at the directive start only
I would expect
sphinxcontrib-phpdomain
extension to honor natively parsed directive parameters.Sphinx build log:
To reproduce this issue, edit any rst sphinx project like:
conf.py:
requirements.txt
sphinx<5 sphinx-rtd-theme sphinxcontrib-phpdomain +myst-parser
The text was updated successfully, but these errors were encountered: