quarto-webr v0.4.0 Released - Ball of Yarn!

software-releases
quarto
webr
Author

TheCoatlessProfessor

Published

February 5, 2024

We’re pleased to bring you the latest release of the quarto-webr extension, v0.4.0. This release brings an entirely new internal backend that improves the reliability and visual cues for non-interactive code cells. Additionally, the extension now supports a custom JSON format for code cell data and options. This has allowed for the introduction of more advanced code cell options, such as autorun that automatically runs code on document open. These options can be set in the code cell using standard hashpipe Quarto option style.

For more details on the changes, please see the news entry below

quarto-webr news file entry for version 0.4.0 (2024-02-05)

Breaking changes

  • Internal JavaScript functions used by the extension have been significantly changed.
  • JavaScript initialization procedure has been further refined.

Features

  • Optimized the underlying code handling insertion and execution of R code. (#118)
  • Implemented a custom JSON format for code cell data and option sharing between Quarto and webR. (#120)
  • Redesigned non-interactive cells to provide improved reliability and visual cues. (#120)
  • Interactive cells now have a toolbar above them that provides three actions: Run Code, Start Over, and Copy. (#91)
  • Initial code cell option support (#104, #117, #125, #151):
    • quarto-webr: context and autorun.
    • Attributes: label and classes.
    • Figures: fig-cap, dpi, fig-width, fig-height, out-width, & out-height.
    • Cell output: warning/message, results, and output
  • Added repos document meta option key to specify custom package repositories containing compiled R WASM Packages not found in the main webR repository (#124, #132).

quarto-webr-autorun-interactive-areas

Changes

  • Added new CSS IDs governing the webR initialization state. (#110)
  • Added shim that overrides install.packages() with webr::install() through webr::shim_install() this requires webR v0.2.2 to be in use. (#122)
  • Added the keyboard shortcut for Run Code – Shift + Enter – to mouseover text for the Run Code button. (#91)
  • Allow {webr-r} code cell to propagate into Quarto markdown formats for hugo-md. (#150, h/t @ClaudiuPapasteri)
  • Updated the version of the MonacoEditor from 0.43.0 to 0.45.0. (#130)
  • Updated the version of the FontAwesome from 6.4.2 to 6.5.1. (#131)

Bugfixes

  • Prevented HTML output being shown as HTML by replacing HTML characters like <, >, &, etc., with their corresponding HTML entities. (#115, h/t @gvelasq)
  • Fixed display of text found after a code cell in RevealJS appearing off the page. (#102, #106)
  • Fixed setup and output contexts not syncing with values found in packages. (#114, #105, #88)
  • Fixed unexpected input error appearing spuriously on Windows machines by enforcing the end-of-line (EOL) character to be LF (\n) and, thus preventing CRLF (\r\n) from entering the picture. (#94 huge thank you and h/t to @ute. Thanks also to @alexCardazzi for initial reporting).

Documentation

Deployment

  • Added an instructive error message regarding whether template files are missing. (#107)

GitHub Changelog