Skip to main content

JSON Schema renderer for Sphinx

Project description

A JSON Schema renderer for Sphinx

Installation

As simple as it can be with pip:

pip install sphinx-json-schema

Usage

Add the extension name to your conf.py:

extensions = [
   ...
   'sphinx_json_schema',
   ...
]

If necessary, add a root directory to look for json schemas:

json_schema_root_dir = os.path.join('path', 'to', 'root', 'dir')

In your documentation:

.. json-schema:: path/to/json/schema.json

The file is looked up relatively from the .rst file the directive is called in, or, if not found from the json_schema_root_dir specified in the conf.py file.

allOf, oneOf, anyOf, not support

sphinx_json_schema supports the allOf, oneOf, anyOf and not keywords. It can also parse references to other schemas. The final JSON output is the result of the operations and inclusions of other schemas. This means it can be quite long even if the original .json file is very short!

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_json_schema-0.1b6.tar.gz (6.3 kB view details)

Uploaded Source

File details

Details for the file sphinx_json_schema-0.1b6.tar.gz.

File metadata

  • Download URL: sphinx_json_schema-0.1b6.tar.gz
  • Upload date:
  • Size: 6.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.18.4 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.5

File hashes

Hashes for sphinx_json_schema-0.1b6.tar.gz
Algorithm Hash digest
SHA256 209ace0ecaab6686eb7d69eda17d58fe3c49d2c323f54621ef6575c9fc889396
MD5 a8ca6e74564abe4587c2de003135fe6f
BLAKE2b-256 f67e0a7d802595deb6df51ec15938400664b23043b4fe42a8733b8d7834f890c

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