An R package containing an RStudio Addin to insert pre-written fenced-divs, classes and markers into your Quarto documents.
See the package website for the full list of available functions and the Quarto website for full Quarto documentation.
Why 'quartostamp'? Historically, pre-prepared blocks were stamped physically into paper quartos. Now you can digitally stamp pre-prepared blocks into your Quarto file.
Install the development version from GitHub:
install.packages("pak") # if not yet installed
# pak::pak("matt-dray/quartostamp")
install.packages("quartostamp", repos = c('https://matt-dray.r-universe.dev', 'https://cloud.r-project.org'))
Restart RStudio to add the functions to the Addins menu.
To use:
So, if you're writing a Revealjs presentation, you might highlight this text in your qmd file:
Here is some text.
And then select 'Insert speaker notes' from the Addins menu to get this:
::: {.notes}
Here is some text.
:::
If you hadn't selected any text, you would get the skeleton:
::: {.notes}
Speaker notes (press 's' when presenting to switch to speaker mode).
:::
You could create custom RStudio keyboard shortcuts for these functions:
You could also use the functions as ordinary R functions.
Use the help files or documentation site to learn more about each one.
They all start with stamp_ so you can search for help files from the R console like ?stamp_notes.
Other packages can be used alongside {quartostamp} when writing a document:
##) to signify a level-two headertags$h2() will insert <h2></h2> for a level-two headerPlease add requests as GitHub issues, or raise a pull request.