From the course: Bootstrap 4 Essential Training
Unlock the full course today
Join today to access over 22,400 courses taught by industry experts or purchase this course individually.
Use badges - Bootstrap Tutorial
From the course: Bootstrap 4 Essential Training
Use badges
- [Instructor] One of the small new features in Bootstrap is the addition of a class for badges. I really like this new addition so let's take a look. Here you can see that the main class for badges is called badge, and then, in addition to that, you have a slightly different shape for the badges, called badge-pill. You can also use the traditional contextual classes. One thing about badges is that they are contextual, so they will resize according to the container. So let's take a look at how that works in real life. Let's go ahead and go to the top of this, and we'll convert this to a, just a span. Usually badges go in spans, and we'll give this a class of badge, and we'll also use the badge-default. Now, this gets, sort of this size font, and let's just go ahead and grab this one from here, and we'll kind of add a badge to this grooming section, we'll call it new here, and we'll use the danger contextual class, so if we scroll down here you should see grooming get this new badge…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.