Skip to main content

No project description provided

Project description

sphinx-expose-init-alias

pypi Main

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

sphinx_expose_init_alias-0.2.0.tar.gz (6.7 kB view details)

Uploaded Source

Built Distribution

sphinx_expose_init_alias-0.2.0-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file sphinx_expose_init_alias-0.2.0.tar.gz.

File metadata

File hashes

Hashes for sphinx_expose_init_alias-0.2.0.tar.gz
Algorithm Hash digest
SHA256 1ca1bafda14c37f663d01341af529cba04057088b8da7179f1fa53c1ccf13b62
MD5 5d75bc76ad883d5929239dea7bd0e334
BLAKE2b-256 8ed90043f4d7a03ffb998cd7bd454c0d407ec0a8abc771b29b3039795b709746

See more details on using hashes here.

File details

Details for the file sphinx_expose_init_alias-0.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for sphinx_expose_init_alias-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 765b8d0da61ec75a9f9622c3b55263bdd7414d713db5b831eda80acee5c662b1
MD5 0efaf2b55f49d743ebe029f9a2cc81ba
BLAKE2b-256 0c8e06b2b6f4236f1cf76768e77a5852136d0ce8813795ff25e0d3f767c7f00b

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page