.onLoad <- function(libname, pkgname){
pkgs <- c(
"magrittr","dplyr","purrr", "tidyr", "stringr", "forcats", "rvest",
"modelr", "testthat")
for(pkg in pkgs){
setHook(packageEvent(pkg, "attach"),
function(...) fastpipe_first())
}
}
fastpipe_first <- function(){
detach("package:fastpipe")
library(fastpipe, warn.conflicts = FALSE, quietly = TRUE )
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.