MkDocs plugin and extension to creates mindmaps from markdown using markmap
Project description
mkdocs-markmap
Beautiful and simple mindmaps written in markdown.
This is a plugin and an extension for mkdocs to add markmap.
Prerequisits
This plugin was tested with, but is not limited to:
- Python 3.9
- mkdocs 1.3
Quickstart
Install
pip install mkdocs-markmap
Configure
Add this to mkdocs.yml
:
plugins:
- markmap
Usage
This plugin supports code blocks of markdown as follows:
```markmap
# Root
## Branch 1
* Branchlet 1a
* Branchlet 1b
## Branch 2
* Branchlet 2a
* Branchlet 2b
```
It can also make use of file includes to keep your markdown tidy:
Look at this beautiful mindmap:
{!mindmap.mm.md!}
Advanced Settings
There are more options available for mkdocs.yml
(shown values are defaults):
plugins:
- markmap:
base_path: docs
encoding: utf-8
file_extension: .mm.md
d3_version: 7
lib_version: 0.15.3
view_version: 0.15.3
In addition, feel free to define your favourite source urls like this:
plugins:
- markmap:
# disable the default assets first
d3_version: ''
lib_version: ''
view_version: ''
extra_javascript:
- https://unpkg.com/d3@7/dist/d3.min.js
- https://unpkg.com/markmap-lib@0.15.3/dist/browser/index.js
- https://unpkg.com/markmap-view@0.15.3/dist/browser/index.js
Troubleshooting
Nav tree lists markmaps
- Move your markmap files to a separate folder next to
docs
, e.g.mindmaps
- Configure
base_path
accordingly (see Advanced Settings)
Static javascript files not working
- Ensure naming of javascript files matches the scheme (see Advanced Settings)
- Copy all javascript files to
doc/js/
, otherwisemkdocs
will not copy static files tosite/
- Define all files in
extra_javascript
, e.g.
extra_javascript:
- js/markmap-d3.js
- js/markmap-lib.js
- js/markmap-view.js
Usage of proxy is preventing download of javascript files
Usually proxies should be supported by requests
, which is used for downloading all required javascript files. If the issue remains, try downloading the files yourself and store them accordingly (see Static javascript files not working)
Credits :clap:
Some of the development approaches are based on implementations provided by the following projects:
- markmap (key feature of this project)
- markdown-include (basis for extension support)
- mkdocs-mermaid2-plugin (basis for plugin support)
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 mkdocs-markmap-2.4.0.tar.gz
.
File metadata
- Download URL: mkdocs-markmap-2.4.0.tar.gz
- Upload date:
- Size: 9.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.17
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bf1b6d599a012f1b7d0e2aea1640bb297d82aca2ebf51fb20e5d158f764e1cfe |
|
MD5 | ddaeae4ce14daa0fcb70c121f4aef99c |
|
BLAKE2b-256 | 1625252849a34e562329cb158921941618b3cf409a5361cf33f84ed3adc40bec |
File details
Details for the file mkdocs_markmap-2.4.0-py3-none-any.whl
.
File metadata
- Download URL: mkdocs_markmap-2.4.0-py3-none-any.whl
- Upload date:
- Size: 10.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.17
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b257935a642390ac872397464f766ecccd03bee1a25bf48d926d302326ede0b4 |
|
MD5 | a2bf7271fe32b88d221cf4168a5acb67 |
|
BLAKE2b-256 | ca9900ae92a18f8d0b3a15541e7bd0b349f34d0b8190300afc69bd53aed181e1 |