Add Jupyterlite REPL example

This commit is contained in:
Caspar Jungbacker 2023-05-07 15:19:27 +02:00
parent 84943db144
commit 7170d2607e
4 changed files with 22 additions and 1 deletions

View file

@ -8,3 +8,6 @@ execute:
sphinx:
extra_extensions:
- sphinx_inline_tabs
- jupyterlite_sphinx
config:
jupyterlite_config: jupyterlite-config.json

View file

@ -9,4 +9,5 @@ parts:
- file: installation-and-setup/jupyter-book-setup
- caption: Cookbook
chapters:
- file: cookbook/recipes.md
- file: cookbook/recipes.md
- file: cookbook/jupyterlite.md

View file

@ -0,0 +1,9 @@
# Interactive elements with Jupyterlite-Sphinx
```{eval-rst}
.. replite::
:kernel: python
:height: 600px
print("test")
```

8
jupyterlite-config.json Normal file
View file

@ -0,0 +1,8 @@
{
"LiteBuildConfig": {
"federated_extensions": [
"https://github.com/jupyterlite/pyodide-kernel/releases/download/v0.0.5/jupyterlite_pyodide_kernel-0.0.5-py3-none-any.whl"
],
"ignore_sys_prefix": true
}
}