No project description provided
Project description
sphinx-expose-init-alias
Generate doc of exposed stuff in __init__.py as alias
What-Is-Wanted
We sometimes do "re-expose" in __init__.py
to improve experience of using our library.
Such as
# lib/a.py
def foo():
...
# lib/__init__.py
from .a import foo
But the foo
in lib/__init__.py
will only occur in docs when use sphinx.ext.autodoc
if we put it in the __all__
in lib/__init__.py
.
And wrose thing is that the content is just like a stuff defined in lib/__init__.py
, which is a bit confused and duplicated.
Demo
See this repo's github pages: sphinx-expose-init-alias Docs
Usage
# docs/lib.rst
.. autoaliasmodule:: lib
:members:
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file sphinx_expose_init_alias-0.2.0.tar.gz
.
File metadata
- Download URL: sphinx_expose_init_alias-0.2.0.tar.gz
- Upload date:
- Size: 6.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1ca1bafda14c37f663d01341af529cba04057088b8da7179f1fa53c1ccf13b62 |
|
MD5 | 5d75bc76ad883d5929239dea7bd0e334 |
|
BLAKE2b-256 | 8ed90043f4d7a03ffb998cd7bd454c0d407ec0a8abc771b29b3039795b709746 |
File details
Details for the file sphinx_expose_init_alias-0.2.0-py3-none-any.whl
.
File metadata
- Download URL: sphinx_expose_init_alias-0.2.0-py3-none-any.whl
- Upload date:
- Size: 5.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 765b8d0da61ec75a9f9622c3b55263bdd7414d713db5b831eda80acee5c662b1 |
|
MD5 | 0efaf2b55f49d743ebe029f9a2cc81ba |
|
BLAKE2b-256 | 0c8e06b2b6f4236f1cf76768e77a5852136d0ce8813795ff25e0d3f767c7f00b |