Skip to main content

Griffe extension adding support for data-class like things (pydantic, attrs, etc...)

Project description

griffe-fieldz

License PyPI Python Version CI codecov

Griffe extension adding support for data-class like things (pydantic, attrs, etc...). This extension will inject the fields of the data-class into the documentation, preventing you from duplicating field metadata in your docstrings.

It supports anything that fieldz supports, which is currently:

Installation

With pip:

pip install griffe-fieldz

To use the extension in a MkDocs project, use this configuration:

# mkdocs.yml
plugins:
- mkdocstrings:
    handlers:
      python:
        options:
          extensions:
          - griffe_fieldz

You may use any of the following options, provided as a dictionary under the griffe_fieldz key.

Option Description Default
include_inherited Include inherited fields in class parameters. False
include_private Include private fields in the documentation. False

For example:

        options:
          extensions:
          - griffe_fieldz: {include_inherited: true}

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

griffe_fieldz-0.2.0.tar.gz (7.8 kB view details)

Uploaded Source

Built Distribution

griffe_fieldz-0.2.0-py3-none-any.whl (5.4 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: griffe_fieldz-0.2.0.tar.gz
  • Upload date:
  • Size: 7.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.0 CPython/3.12.5

File hashes

Hashes for griffe_fieldz-0.2.0.tar.gz
Algorithm Hash digest
SHA256 fba1ecadb4d19e7f1c7b87e13caadd426f7066bd8f4bbb53615bd035bf67be58
MD5 6c5a69932aabd318f3ae3250f9e2df3f
BLAKE2b-256 acbf36adba8f47bcbbcfe9950649b35be62d2fc567229a541af24db0ef37c2a3

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for griffe_fieldz-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c2ebb0c63e7b660ddcc7c94237c6309a6bce998552b8c3483f0c14016fabf949
MD5 cc24f24d452f11fe7d505918c2e7643f
BLAKE2b-256 24c29fb0cb0023d14d6a443e8215a5d67393d2a93e41a4ba26e5a1393d433172

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