Sometimes, we want to add a vertical divider between two columns in Bootstrap and HTML.
In this article, we’ll look at how to add a vertical divider between two columns in Bootstrap and HTML.
How to add a vertical divider between two columns in Bootstrap and HTML?
To add a vertical divider between two columns in Bootstrap and HTML, we add the border-right
class.
For instance, we write
<div class="row">
<div class="col-6 border-right"></div>
<div class="col-6"></div>
</div>
to add the border-right class to add a right border to the left div.
This class is available with Bootstrap 4.
Conclusion
To add a vertical divider between two columns in Bootstrap and HTML, we add the border-right
class.