bs_remove | R Documentation |
A Bootstrap theme created with bs_theme()
is comprised of
many Sass layers.
bs_remove()
and bs_retrieve()
allow you to remove or retrieve an
individual layer, either to reduce the size of the compiled CSS or to extract
styles from a theme.
bs_remove(theme, ids = character(0))
bs_retrieve(theme, ids = character(0), include_unnamed = TRUE)
theme |
A |
ids |
a character vector of ids |
include_unnamed |
whether or not to include unnamed |
Returns a modified bs_theme()
object.
Other Bootstrap theme functions:
bs_add_variables()
,
bs_current_theme()
,
bs_dependency()
,
bs_global_theme()
,
bs_theme()
,
bs_theme_dependencies()
,
bs_theme_preview()
bs4 <- bs_theme(version = 4)
# Retrieve sass bundle for print styles
bs_retrieve(bs4, "_print", include_unnamed = FALSE)
# Remove CSS rules for print and carousels
bs4_no_print <- bs_remove(bs4, c("_print", "_carousel"))
suppressWarnings(
bs_retrieve(bs4_no_print, "_print", include_unnamed = FALSE)
)
# Remove BS3 compatibility layer
bs4_no_compat <- bs_remove(bs4, "bs3compat")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.