.onLoad <- function(libname, pkgname) {
op <- options()
op.icon <- list(
icon.path = rappdirs::user_data_dir("rpkg_icon")
)
toset <- !(names(op.icon) %in% names(op))
if (any(toset)) options(op.icon[toset])
# Update icon details
update_icon()
invisible()
}
.onAttach <- function(...) {
crayon::num_colors(TRUE)
icon_attach()
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.