Skip to main content

Crystal language doc generator for mkdocstrings

Project description

mkdocstrings-crystal

Crystal language doc generator for MkDocs, via mkdocstrings

PyPI GitHub GitHub Workflow Status

Introduction

mkdocstrings-crystal allows you to insert API documentation (generated from Crystal's source code and doc comments) as part of any page on a MkDocs site.

See it in action.

To install it, run (possibly in a virtualenv):

pip install mkdocstrings-crystal

Continue to the documentation site.

Usage

With MkDocs, add/merge this base config as your mkdocs.yml:

site_name: My Project

theme:
  name: material

plugins:
  - search
  - mkdocstrings:
      default_handler: crystal

markdown_extensions:
  - pymdownx.highlight
  - deduplicate-toc

Then, in any docs/**/*.md file, you can mention a Crystal identifier alone on a line, after ::::

::: MyClass

::: Other::Class#some_method

::: Foo::CONSTANT

-- and in the output this will be replaced with generated API documentation for it, much like Crystal's own doc generator does.

This, of course, happens as part of a normal MkDocs build process:

mkdocs build  # generate from docs/ into site/
mkdocs serve  # live preview

Continue to the documentation site.

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

mkdocstrings_crystal-0.3.7.tar.gz (16.9 kB view details)

Uploaded Source

Built Distribution

mkdocstrings_crystal-0.3.7-py3-none-any.whl (20.7 kB view details)

Uploaded Python 3

File details

Details for the file mkdocstrings_crystal-0.3.7.tar.gz.

File metadata

  • Download URL: mkdocstrings_crystal-0.3.7.tar.gz
  • Upload date:
  • Size: 16.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.6

File hashes

Hashes for mkdocstrings_crystal-0.3.7.tar.gz
Algorithm Hash digest
SHA256 6d0b2fc8ef1256aec2cc4ff22a7d5aff6398c574cede10a5941e5aa3590012c7
MD5 9af0b7588f05e220f82b0b37ff1942ad
BLAKE2b-256 d84be1a997348e6abe048f7a84b85c48b0e6bf501fc3f6c3e3a7dfc4ee9a4086

See more details on using hashes here.

File details

Details for the file mkdocstrings_crystal-0.3.7-py3-none-any.whl.

File metadata

File hashes

Hashes for mkdocstrings_crystal-0.3.7-py3-none-any.whl
Algorithm Hash digest
SHA256 91f25700a1e13ee5157aa5875441d333830c392d5ace7ef1c2106d9e5b2883b6
MD5 d12b956aa9fcc1e73da02fe63a61804e
BLAKE2b-256 8063ae7f6d546d8e74fa4aee6d17d829cb8c600583c3ab5a1b0e1e3da5dda23a

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