Introduction

WebAssembly powered code blocks and exercises for Quarto HTML documents

Embed WebAssembly powered code blocks and exercises for both the R and Python languages into Quarto documents with HTML-based output formats.

Quarto Live

The quarto-live extension provides:

  • Interactive R and Python code blocks.

  • Exercises with optional hints, solutions, and custom grading algorithms.

  • Rich output for showing client-side interactive plots, images, and HTML widgets.

  • A CodeMirror-based text editor with automatic theming, syntax highlighting, and auto-complete.

  • Integration with OJS so that interactive code cells update reactively with ojs cells.

The webR and Pyodide WebAssembly engines are used to dynamically execute code in the user’s web browser, so only a static web service (such as GitHub Pages, Quarto Pub, or Netlify) is required.

Demo

Next steps

Work through the Getting Started sections to learn how to install quarto-live and use interactive code blocks in your documents.