Bootstrap collapse component is used to simply show and hide different sections and subsections of your web page. This is useful when you don't want the sections to be visible initially, but will toggle when clicked on a button or hyperlink. Here is a simple example:
Here is the HTML code for the preceding screenshot:
<button class="btn btn-primary" type="button" data-toggle="collapse" data-target="#theSection" id="theButton">Open this</button> <div class="collapse" id="theSection"> <div class="well"> this content is coming from the collapsible section. </div> </div>
// When ...