![]() |
VOOZH | about |
behaviorBootstrap 5 Checks and radios Default (stacked) is used to create a stack of checks and radios as a list. To create a stack we need to put the checks and radios normally one by one that will create stacks it's the default behaviour of Bootstrap 5 Checks and radios.
Bootstrap 5 Checks and radios Default (stacked) Class: There is no pre-defined class to create the stacks we just need to put multiple checks and radios one by one that will stack them up.
Syntax:
<div class="form-check"> <input class="form-check-input" type="checkbox" value=""> <label class="form-check-label" for="inputID"> ... </label> </div>
Below examples illustrate the Bootstrap 5 Checks and radios Default (stacked):
Example 1: In this example, we will learn about Stacked Checkboxes.
Output:
Example 2: In this example, we will learn about Stacked Radio Buttons.
Output:
Reference: https://getbootstrap.com/docs/5.0/forms/checks-radios/#default-stacked