Skip to main content

Excalidraw drawings in mkdocs

Reason this release was yanked:

broken because of CICD issue

Project description

Mkdocs Excalidraw

✨ A simple mkdocs plugin to easily embed your excalidraw drawings into your docs

See it in action here

🎯 Features

  • Embed your drawings as you would an image by converting your excalidraw drawings to svg on the fly
  • Dark mode compatibility for mkdocs and mkdocs-material themes
  • Lightbox support when used with mkdocs-glightbox (fullscreen on click)
  • Select which frame of the drawing to display

📦 Installation

Install the package

pip install mkdocs-excalidraw

Add it to your mkdocs.yaml

site_name: MkDocs Excalidraw
plugins:
  - excalidraw
  - glightbox # if you want lightbox (see below)

🚀 Usage

You can use this project's docs as an example , lets break down how we do it.

  1. Create an excalidraw drawing and save the file (I recommend using the vscode extension)
  2. Add a reference to it in your markdown file as you would for an image
![fig_name](drawings/test.excalidraw)
  1. Thats it , the extension renders it as an svg in your browser

🧩 Integrations

🌓 Dynamic Theme

This extensions supports dynamic light/dark theme with the following mkdocs themes:

  • material-mkdocs
  • mkdocs (base)

This means that , when you switch the the between light and dark , the excalidraw drawings will change their theme accordingly

🖥 GLightbox - fullscreen and slideshow

Simply install and setup mkdocs-glightbox as descibed here. once done your mkdocs drawing will be clickable , and available in the slideshow of the page.

🪟 Frame based rendering

Excalidraw introduced the notion of frame. You can select a part of your drawing to be part of a frame ,a drawing can hold several frames. But an object can only belong to one frame.

to render not the whole drawing but a specific frame , you can do the following :

![alt](drawings/test.excalidraw#frame-name)

This feature pairs nicely with glightbox (just above) and enables you to turn an mkdocs page into a slideshow !

🫶 Contributing

This projects welcomes contribution ! But contribution does not have to be code. Here are great ways to help this project :

  • Fill in a detailed bug report (with console logs , screenshots and execution context)
  • Make a feature requests
  • Make a PR for the documentaion to impprove it or translating it
  • Make a code PR but please link it to an issue

And if you have a few seconds to star this repo it would really help us reach more people ! We hope you like this plugin at least as much as we loved making it

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

mkdocs_excalidraw-0.5.1.tar.gz (7.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mkdocs_excalidraw-0.5.1-py3-none-any.whl (8.4 kB view details)

Uploaded Python 3

File details

Details for the file mkdocs_excalidraw-0.5.1.tar.gz.

File metadata

  • Download URL: mkdocs_excalidraw-0.5.1.tar.gz
  • Upload date:
  • Size: 7.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.12.12 Linux/6.11.0-1018-azure

File hashes

Hashes for mkdocs_excalidraw-0.5.1.tar.gz
Algorithm Hash digest
SHA256 37e49c5520ccf3b6e7b0684df969c172a130ee62e615910df7cf8234897a7adc
MD5 a1299e5627150466d1cae8c957c353a9
BLAKE2b-256 77b8dd022687cd3394055a7a8eaebacfdf0f99e8374e74afc48c58caf778ed2a

See more details on using hashes here.

File details

Details for the file mkdocs_excalidraw-0.5.1-py3-none-any.whl.

File metadata

  • Download URL: mkdocs_excalidraw-0.5.1-py3-none-any.whl
  • Upload date:
  • Size: 8.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.12.12 Linux/6.11.0-1018-azure

File hashes

Hashes for mkdocs_excalidraw-0.5.1-py3-none-any.whl
Algorithm Hash digest
SHA256 6445bd91301b25a7df53ee151a15013457400f15d4c855a118da40602c1f263e
MD5 9c8e87827eec3fe5d43f9fc6b989fc27
BLAKE2b-256 147ce0d250fb1b20aeea4e9b309ae964ddbcc89d1a75b3982c11552cb6c4201a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page