#' Escape regex
#'
#' @param x character
#'
#' @return escaped version of x
#' @export
escape <- function(x) {
pattern <- r"--((?=[-\[\]{}()\*\+\?\.\,\\\^\$\|\#]))--"
gsub(pattern, r"(\\)", x, perl = TRUE)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.