mkdocs-pivot-table
A lightweight MkDocs plugin that renders interactive, sortable, and filterable comparison tables directly in your documentation.
Features
- Sortable columns – Click any column header to sort ascending/descending
- Drag-to-reorder – Drag column headers to change order
- State preservation – View state is saved to the URL (shareable links) and localStorage
- Hide/show columns – Toggle individual columns via toolbar buttons
- Hide/show rows – Toggle individual rows via toolbar buttons
- Swap rows/columns – Transform the table orientation with one click
- Reset button – Restore the original view
- Zero config – Works out of the box with minimal setup
Installation
Add to your requirements.txt:
-e git+https://github.com/Aldo-f/mkdocs-pivot-table.git#egg=mkdocs-pivot-table
Or install from PyPI (when published):
pip install mkdocs-pivot-table
Then enable the plugin in your mkdocs.yml:
plugins:
- mkdocs_pivot_table
Usage
Place a table in your markdown using the [pivot-table] wrapper:
[pivot-table]
| Feature | npm | pnpm | Bun | pip | uv |
|---------|-----|------|------|-----|----|
| Speed | Slow | Fast | Fastest | Slow | Fast |
| Dedup | No | Yes | Yes | No | Yes |
| Runtime | No | Yes | Yes | No | Yes |
| Maturity| High| High | Medium| High| Medium|
[/pivot-table]
The table will render as an interactive <table> with:
- Sorting: Click column headers to sort
- Reordering: Drag column headers to reorder
- Filtering: Use toolbar buttons to hide/show columns or rows
- Swapping: Click "Swap R/Col" to transpose the table
- Sharing: The current view is reflected in the URL
Configuration
Optional configuration in mkdocs.yml:
plugins:
- mkdocs_pivot_table:
asset_url: "https://cdn.jsdelivr.net/npm/pivot-table-kit@0.1.0/dist/pivot-table.js"
asset_inline: false
| Option | Default | Description |
|---|---|---|
asset_url |
CDN URL | External JavaScript asset URL |
asset_inline |
false |
Whether to inline the JS instead of loading from URL |
Requirements
- MkDocs ≥ 1.5.0
- Python ≥ 3.9
License
MIT
Metadata
Release files for mkdocs-pivot-table 0.4.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| mkdocs_pivot_table-0.4.0-py3-none-any.whl | Python 3 | none | any | Details for mkdocs_pivot_table-0.4.0-py3-none-any.whl |
Release files / mkdocs_pivot_table-0.4.0-py3-none-any.whl
| Download URL | mkdocs_pivot_table-0.4.0-py3-none-any.whl |
|---|---|
| Size | 11.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b61e95657d50e3edd7b1284f029030a5951044c2716cec4dc85306b79742f780
|
|
BLAKE2b-256 checksum How to use checksums |
bd1a88c47218a917c95ee55ff11fdd4acba7ed86cc304df730113ed89f1c0aa5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.5
|
Security for mkdocs-pivot-table 0.4.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.