marimo for MkDocs
A MkDocs plugin that brings interactive Python code execution to your documentation using marimo.
Features
- ⚡️ Write and execute Python code directly in your Markdown files
- 🔄 Interactive widgets with real-time updates
- 📊 Seamless integration with data visualization libraries
- 🎨 Customizable styling to match your documentation theme
- 🚀 Easy to set up and use
Quick Start
1. Install the plugin
2. Add the plugin to your mkdocs.yml
3. Write interactive Python code in your Markdown files
```python {marimo}
import marimo as mo
name = mo.ui.text(placeholder="Enter your name")
name
```
```python {marimo}
mo.md(f"Hello, **{name.value or '__'}**!")
```
Example: Interactive Sine Wave
Instead of static code blocks, create interactive visualizations:
Why mkdocs-marimo?
- Interactive Documentation: Engage your readers with live, interactive code examples.
- Real-time Feedback: Instantly see the effects of code changes and parameter adjustments.
- Enhanced Learning: Improve understanding through hands-on experimentation within the documentation.
Getting Started
Check out our Getting Started guide to learn more about using marimo inside MkDocs.
Community
- GitHub Issues: Report bugs or request features
- Discord: Ask questions and share ideas
License
mkdocs-marimo is released under the Apache License 2.0.