Quarto Extension to Embed webR for HTML Documents, RevealJS, Websites, Blogs, and Books.
read-only
is a new code cell option that prevents changes to code inside of an interactive
context.embed-resources: true
was set. (#95)[!NOTE]
The
embed-resources
option only works if the communication channel is either"automatic"
(default),"post-message"
, or"shared-array-buffer"
. Do not attempt to use it with"service-workers"
.
plot2
to tinyplot
due to a name change upstream.{webr-r}
code blocks.context
and autorun
.label
and classes
.fig-cap
, dpi
, fig-width
, fig-height
, out-width
, & out-height
.warning
/message
, results
, and output
repos
document meta option key to specify custom package repositories containing compiled R WASM Packages not found in the main webR repository (#124, #132).install.packages()
with webr::install()
through webr::shim_install()
this requires webR v0.2.2 to be in use. (#122)Shift + Enter
-- to mouseover text for the Run Code button. (#91){webr-r}
code cell to propagate into Quarto markdown
formats for hugo-md
. (#150, h/t @ClaudiuPapasteri)<
, >
, &
, etc., with their corresponding HTML entities. (#115, h/t @gvelasq)setup
and output
contexts not syncing with values found in packages
. (#114, #105, #88)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).{webr-r}
cells.{quarto-webr}
and showing the underlying code.webr-worker.js
and webr-serviceworker.js
files are no longer required to be present with the document under default options.pandoc
. For more details, please see Issue #14.webr-worker.js
and webr-serviceworker.js
scripts. (#59)_quarto.yml
to the meta options (#46)autoload-packages
document meta option key that will automatically load packages specified in the packages
key. The default value is true
. (#75)
library()
in interactive code cells or setup code cells, as the specified packages will be loaded automatically.revealjs
presentation format. (#84)tests/
directory that contains Quarto documents used across multiple browsers before triggering a point release. (#76)open-in-html-browser
extension to devcontainer for better previewing options of HTML results.package
key. (#68)pager
event types. (#58)
base-url
to allow for a localized version of webR
away. (#54)packages
meta option not installing packages if the status bar was not present (#69)channel-type: 'automatic'
(#74)examples/
directory containing examples for HTML Documents, Books, and Websites. (#53)quarto-webr
extension in the wild.channel-type
sets the communication channel webR uses.
channel-type: automatic
(default): Communicates using either shared-array-buffer
or service-worker
.channel-type: shared-buffer-array
: Fastest communication option, but requires setting up HTTP headers.channel-type: service-worker
: Slower communication option and requires worker scripts to be next to the rendered document.channel-type: post-message
: Easiest setup option at the expense of being unable to interrupt the R process or accept user-input.context
controls whether the code and output are shown or suppressed.
context: interactive
(default) shows both code and output.context: setup
suppresses both code and output.context: output
suppresses code but shows its output.#| context: <value>
like so:```{webr-r}
#| context: setup
my_hidden_variable = 11
```
docs
folder inside the repository to host the documentation website._extension
directory into docs
to avoid needing to add the extension on each render.quarto-webr
documents requiring a reload in Safari to see/interact with code cells (#21)