spec_repo <- function (repo_spec) {
parse_repo_spec(repo_spec)$repo
}
spec_owner <- function (repo_spec) {
parse_repo_spec(repo_spec)$owner
}
parse_repo_spec <- function (repo_spec) {
repo_split <- strsplit(repo_spec, "/")[[1]]
list(owner = repo_split[[1]], repo = repo_split[[2]])
}
label_attr <- function(x, l, mapper = purrr::map_chr) {
mapper(l, x, .default = NA)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.