Skip to main content

PyMdown Extensions Blocks

Ruff PyPI - Version PyPI - Python Version Tests

These are a collection of blocks for the PyMdown Extensions that I find useful.

This project is not affiliated with the PyMdown Extensions project and is currently in a very early stage. Currently, there is only one block: DirTree.

Installation

pip install pymdownx-blocks

Usage

This can be used in MkDocs or by itself. To use in a Python file, we use the following:

import markdown

yaml_str=...
md=markdown.Markdown(extensions=['pymdownx_blocks.dirtree'])

To use in MkDocs, register the extension.

...
markdown_extensions:
...
- pymdownx_blocks.dirtree
...

In a markdown file,

///dirtree

root:
- subdir:
  - File
- another subdir:
  - anotherfile.txt
  - file.csv
///

When rendered, this will produce the following tree

Directory Structure

root ├── subdir │ └── File └── another subdir ├── anotherfile.txt └── file.csv

Contributing

More blocks are always welcome! This project uses rye for dependency management.

  1. Fork the repository
  2. Create a branch with the name of the block
  3. Implement the block
  4. Create a pull request.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pymdownx_blocks-0.1.1.tar.gz (4.5 kB view details)

Uploaded Source

Built Distribution

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

pymdownx_blocks-0.1.1-py3-none-any.whl (5.2 kB view details)

Uploaded Python 3

File details

Details for the file pymdownx_blocks-0.1.1.tar.gz.

File metadata

  • Download URL: pymdownx_blocks-0.1.1.tar.gz
  • Upload date:
  • Size: 4.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.7

File hashes

Hashes for pymdownx_blocks-0.1.1.tar.gz
Algorithm Hash digest
SHA256 fa2e4c1f52281a3f183b85ba03d595ab2815330482de2cb354c800df2b15b170
MD5 8a6155b5390fae3d4504c1d8f6bcc857
BLAKE2b-256 87b215655e04783377c307a8d4b3ce3d8fc9f66e7e69ce70b29c23eba12cfc75

See more details on using hashes here.

File details

Details for the file pymdownx_blocks-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for pymdownx_blocks-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 02804a2d278e24da210d5178b776991c581706b2847159d0edecc5c4b10cf996
MD5 8ee33ec8964f94323a213437005a67e9
BLAKE2b-256 3248fa1d70cb4918218341df8fcec6b7646eb792bbc3ed35e21075feb466ca1d

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 files

0.1.0

2 files

Supported by

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