Skip to article frontmatterSkip to article content

Announcing the Jupyter Book 2 alpha

Rebuilt from the ground up for prettier PDFs, richer websites, and better tooling.

Authors
Affiliations
Jupyter Book
2i2c
Jupyter Book
2i2c
Jupyter Book
Curvenote
Jupyter Book
Curvenote
Jupyter Book
Curvenote

Over the last ten months, the Jupyter Book team have been hard at work; Jupyter Book has become a Jupyter subproject, and the team[1] announced a plan to release Jupyter Book 2. This post announces the alpha release of Jupyter Book 2.0, which has been re-written from the ground up to use the new MyST-MD engine.

Over the next few months, we will work in preparation for the full release of Jupyter Book 2. Stay tuned for more! The initial documentation for the alpha release can be found at:

https://next.jupyterbook.org/

Install the Jupyter Book 2 Alpha

The Jupyter Book 2 alpha is available from PyPI.org. You can install it with pip, using

pip install -U jupyter-book==2.0.0a0

If you use pipx, it’s recommened to run Jupyter Book 2 using

pipx run jupyter-book==2.0.0a0

Jupyter Book 2 needs Node.js installed on your computer. If this is not the case, running jupyter book will prompt you to install it using the nodeenv package that ships with Jupyter Book 2:

❗ Node.js (node) is required to run Jupyter Book, but could not be found`.
❔ Install Node.js in '...'? (y/N):

Press y and Enter to proceed.

New Features in 2.0 alpha

Rich Hover Previews

Try hovering over this tooltip about tooltips!. The new MyST book and article themes provide useful hover previews for links to other MyST content, Wikipedia, GitHub issues, and many more.

Rabbit-hole links in the new MyST engine that powers Jupyter Book 2

Share & Embed Content

Content from other websites built with the MyST engine can be embedded in your own sites and PDFs:

Here’s a cool figure.

Cross-referenced content can easily be embedded and re-captioned into other pages and projects, such as this figure to Figure 1.

A new client-side search uses a simple, modern algorithm for fast local search that finds the results that you care about.

Client-side search uses simple, modern, Algolia-inspired search algorithm to provide useful search results. We will be iterating on this in the near future for even richer search results!

Client-side search uses simple, modern, Algolia-inspired search algorithm to provide useful search results. We will be iterating on this in the near future for even richer search results!

High Quality PDFs

PDF documents can now be built with Typst, a high-quality typesetting engine that produces readable error messages and beautiful documents. This feature was the basis for the 2024 SciPy proceedings, which is now built on MyST Markdown and will be accepting Jupyter Notebooks in 2025.

Example of the LaPreprint Typst template for rendering PDFs from Jupyter Book (via the MyST Engine).

Example of the LaPreprint Typst template for rendering PDFs from Jupyter Book (via the MyST Engine).

Coming Soon in 2.0 beta

Custom Styles & Scrips

Jupyter Book 2 will make it easy to tweak your website styles, and add new website behaviors.

Generate Markdown from Code Cells

The MyST engine is on-track to support the inclusion of references and other markup features generated by code cells.

Control Cell Visibility with Tags

In the beta release, Jupyter Book 2 will once-again be able to show and hide content according to cell tags.

Jupyter Book 2 vs MyST-MD

At this early stage, the new Jupyter Book application jupyter book behaves identically to the mystmd engine that it is built upon; as outlined in our Jupyter Book 2 plan, we intend for Jupyter Book to be an “opinionated distribution” of mystmd that shares the same configuration format and CLI. This contrasts with Jupyter Book 1, which was built on top of the Sphinx documentation engine, but offered its own CLI and configuration files. In future, the jupyter book and mystmd CLIs may diverge from one another, but we expect that this will be handled in a graceful manner: mystmd commands should always be compatible with the jupyter book application.

Footnotes
  1. Jupyter Book project has historically been a technical project of the Executable Books organisation. In 2024, the establishment of a Jupyter subproject means that the Jupyter Book project now has its own identity outside of Executable Books.