Skip to main content

Render marimo cells as hydrated islands in Jupyter Book.

Project description

marimo + Jupyter Book

marimo is a reactive Python notebook that can be embedded in static documents. This repo is a Jupyter Book executable plugin that lets you write marimo cells in MyST pages and publish a static book whose controls, tables, plots, SQL results, and dependent cells still respond in the browser.

Requires Python 3.10+. The package installs marimo for page execution.

Quick Start

1. Install the plugin in the same environment as Jupyter Book:

pip install jupyter-book-marimo

For uv-managed projects, use:

uv add jupyter-book-marimo

2. Register the executable plugin in myst.yml:

project:
  plugins:
    - type: executable
      path: .venv/bin/jupyter-book-marimo

Use the executable path that matches your environment. In this repo's docs site, the docs live in docs/, so the path is ../.venv/bin/jupyter-book-marimo. On Windows, use .venv/Scripts/jupyter-book-marimo.exe, or ../.venv/Scripts/jupyter-book-marimo.exe when myst.yml lives in docs/.

3. Edit a MyST page:

---
title: My reactive page
---

# A reactive page

```{marimo} python
import marimo as mo

slider = mo.ui.slider(start=1, stop=10, step=1, label="items")
slider
```

```{marimo} python
mo.md(f"The slider is set to **{slider.value}**.")
```

Set page defaults or page-local dependencies with {marimo-config}:

```{marimo-config}
:echo: true
:pyproject: |
  requires-python = ">=3.10"
  dependencies = ["pandas"]
```

4. Build the book:

jupyter-book build --html

Features

jupyter-book-marimo uses marimo islands so reactive notebook content can live between ordinary book sections. The plugin supports Python, SQL, and Markdown cells, page-level execution defaults, page-local dependencies, custom styling hooks, and static HTML output that hydrates into interactive marimo components on load.

Docs

Read the user docs at marimo-team.github.io/jupyter-book-marimo.

For the full local development workflow, see CONTRIBUTING.md.

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

jupyter_book_marimo-0.0.2.tar.gz (72.5 kB view details)

Uploaded Source

Built Distribution

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

jupyter_book_marimo-0.0.2-py3-none-any.whl (51.3 kB view details)

Uploaded Python 3

File details

Details for the file jupyter_book_marimo-0.0.2.tar.gz.

File metadata

  • Download URL: jupyter_book_marimo-0.0.2.tar.gz
  • Upload date:
  • Size: 72.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.32 {"installer":{"name":"uv","version":"0.11.32","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for jupyter_book_marimo-0.0.2.tar.gz
Algorithm Hash digest
SHA256 3d15e36ba8257fc1b11ad79e0a35221de3570ea0dfa460af338579db295468a6
MD5 aec67dedb5e95ea166d8bc1c1c0c9004
BLAKE2b-256 152e65d19d4c10798e2a18f62f797bc8a8c3fdb41c9dc553efcd975ff6755e84

See more details on using hashes here.

File details

Details for the file jupyter_book_marimo-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: jupyter_book_marimo-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 51.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.32 {"installer":{"name":"uv","version":"0.11.32","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for jupyter_book_marimo-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 3ca8b7fd7fb56c77135c8db4c39c33f1d94e11ef12a59282908c1a4c0a1f7af1
MD5 23317f4adf561c9660aea2e9639fd5f6
BLAKE2b-256 d1e41d19cb60d71dc7b0533aadbdcb4d9b5df0fdac1899972d1644937a4e980b

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