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.3.tar.gz (16.7 kB view details)

Uploaded Source

Built Distribution

mkdocstrings_crystal-0.3.3-py3-none-any.whl (19.7 kB view details)

Uploaded Python 3

File details

Details for the file mkdocstrings-crystal-0.3.3.tar.gz.

File metadata

  • Download URL: mkdocstrings-crystal-0.3.3.tar.gz
  • Upload date:
  • Size: 16.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.4 CPython/3.9.6 Linux/5.13.10-arch1-1

File hashes

Hashes for mkdocstrings-crystal-0.3.3.tar.gz
Algorithm Hash digest
SHA256 20bb0b3a7f7ff097ff97104da308160b5562ae3644bf5eb8124887665e771bb6
MD5 6f040d388a441a021ec6f7c926d7cb22
BLAKE2b-256 5b96c7fc199e2d85f62f54445bf9c1fe7be7a99089637f099fcb5444efd8cc69

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for mkdocstrings_crystal-0.3.3-py3-none-any.whl
Algorithm Hash digest
SHA256 0ce1502a4a3a2dd634c0b51dd0775a5716caab0e3a985852c7e5d26794b83655
MD5 a3ff8832b7c35dcfb791425619e6801e
BLAKE2b-256 b2cc54fe190cf2474c78e39361e90dbbd33df21775da7dddea7f11209996739d

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