.onAttach <- function(...) {
# See if any packages are needed
needed <- pkgs[!is_attached(pkgs)]
# If no packages are needed, return
if (length(needed) == 0) {
return()
# Otherwise, attach any needed packages
} else {
{{name}}_attach()
}
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.