Bootstrap has created its icon library made for Bootstrap components and documentation. To see how Bootstrap components work, Bootstrap icons are used to change form control into navigation. Bootstrap icons are SVGs that are simple, agile, and designed with CSS. These icons can be easily placed in an HTML file to describe the given code.
Bootstrap icons are added with the <i>
tag and the bi-*
icon class. It has the following syntax:
<i class="bi-class name"></i>// If we have to add icons through font CSS, then its syntax would be:<i class="fa fa-class name"></i>
The bootstrap icons link is installed in the above code to show different icons in HTML code.
bi bi-cart
.bi bi-star
.bi bi-badge-hd
.font
class.font
class to show the google
icon with a button under the div
class.Note: Bootstrap has its library icons that can be installed from nmp (Node package manager contains packages of the node) using thenpm i bootstrap-icons
command. However, there are many methods to add icons in code like CSS and SVGs, using the CDN (Content delivery network for the fast delivery of internet content) link of Bootstrap icons.