bs_collapse | R Documentation |
Learn more at https://getbootstrap.com/docs/5.1/components/collapse/.
bs_collapse( id, button_label, content, button_attr = c(class = "btn btn-primary"), content_attr = c(class = "collapse") )
id |
A string, the id to use for the collapse div. |
button_label |
A string, the text to display in the button controlling the collapsible content. |
content |
A string, the HTML to display or collapse. |
button_attr |
A named list or named vector, names are attribute names and values are attribute values. Added to the button controlling the collapse. |
content_attr |
A named list or named vector, names are attribute names and values are attribute values. Added to the div wrapping the collapsible content. |
A string of HTML.
bs_collapse( id = "collapse1", button_label = "Click to Expand", content = p("Hello") )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.