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_formatter', ... ]
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_formatter 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
Release history Release notifications | RSS feed
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_json_schema_formatter-0.3.7.tar.gz
.
File metadata
- Download URL: sphinx_json_schema_formatter-0.3.7.tar.gz
- Upload date:
- Size: 7.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.1 CPython/3.9.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1c3f25cbd30458311e43a26d56d7b8e8dbf047c41602d2f3a02b589b5bf05f77 |
|
MD5 | 1e0d5c73692ceb4daa04046a912d697b |
|
BLAKE2b-256 | e0b90aa7419ed2cdb7ed923300dc1c3c992db69c16e24c0326d5e67647fc71f0 |
File details
Details for the file sphinx_json_schema_formatter-0.3.7-py3-none-any.whl
.
File metadata
- Download URL: sphinx_json_schema_formatter-0.3.7-py3-none-any.whl
- Upload date:
- Size: 10.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.1 CPython/3.9.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 74627436fcd97de10b6b35f1c8772ca2a931c8494eec14c53277fb043ac7d2fe |
|
MD5 | 5236b1011bd6e63b46dc870564fa0a16 |
|
BLAKE2b-256 | 9defedad7dc20d5d1a7d18483b47a0a55b6836b42038f2a594c52e16eef775fa |