mirror of
https://github.com/TeachBooks/manual.git
synced 2026-11-12 22:35:51 +00:00
Merge pull request #182 from TeachBooks/code-examples
Added Sphinx Extension for Code Examples
This commit is contained in:
commit
f578df2c3a
4 changed files with 8 additions and 1 deletions
|
|
@ -20,6 +20,7 @@ sphinx:
|
|||
- sphinx_image_inverter
|
||||
- sphinx_exercise
|
||||
- sphinx_proof
|
||||
- sphinx_code_examples
|
||||
- sphinx_named_colors
|
||||
- sphinx_iframes
|
||||
- sphinx_prime_applets
|
||||
|
|
|
|||
|
|
@ -90,6 +90,7 @@ parts:
|
|||
- external: https://github.com/TeachBooks/Sphinx-Indexed-Definitions/blob/manual/README.md #BUMP
|
||||
- file: external/Sphinx-PRIME-applets/README.md
|
||||
- external: https://github.com/TeachBooks/Sphinx-Dropdown-Toggle/blob/main/MANUAL.md
|
||||
- external: "https://github.com/TeachBooks/sphinx-code-examples/blob/main/MANUAL.ipynb"
|
||||
- file: features/visuals.md
|
||||
sections:
|
||||
- file: external/Sphinx-Image-Inverter/README.md
|
||||
|
|
|
|||
|
|
@ -173,6 +173,10 @@
|
|||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Exercises and examples with executable code\n",
|
||||
"\n",
|
||||
"To include executable code in your book inside exercises and/or examples, you can use the Sphinx extension [Sphinx-Exercises](https://ebp-sphinx-exercise.readthedocs.io/en/latest/syntax.html#alternative-gated-syntax) and/or the Sphinx extension {ref}`Sphinx-Code-Examples <sphinx-code-examples-gated>`.\n",
|
||||
"\n",
|
||||
"## Alternative with JupyterLite (less well integrated)\n",
|
||||
"\n",
|
||||
"Another option to use python in your browser is to use [JupyterLite](https://jupyterlite.readthedocs.io/en/stable/). However, compared to Sphinx-Thebe, described above, this doesn't give a similar seamless interface within your page. Nevertheless, depending on your application, JupyterLite could be a useful tool, especially as it allows for three IDE types: Jupyter Notebook, Jupyter Lab and the iPython REPL.\n",
|
||||
|
|
@ -181,7 +185,7 @@
|
|||
"\n",
|
||||
"```{tip}\n",
|
||||
"The TeachBooks Team has focused primarily on the use of Sphinx-Thebe and has not looked at JupyterLite over the last couple years. If you have an interesting application of this tool for teaching, please get in touch, we would love to see it! You can use [GitHub Discussions](https://github.com/orgs/TeachBooks/discussions) or sent us an email at [info@teachbooks.io](mailto:info@teachbooks.io).\n",
|
||||
"```"
|
||||
"```\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ sphinx-named-colors == 1.0.1
|
|||
sphinx-iframes == 1.0.5
|
||||
sphinx-prime-applets == 1.0.2
|
||||
sphinx-dropdown-toggle == 1.0.0
|
||||
sphinx-code-examples == 1.0.2
|
||||
|
||||
git+https://github.com/TeachBooks/Sphinx-Thebe
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue