How it works...

The changes made both to the navbar and the carousel are to do mostly with CSS classes that changed their names between the two versions of Bootstrap, with minor changes in their HTML structure.

The way that we changed the components in this recipe highlights the reason why Bootstrap is so popular. We have not once had to open a style sheet. All we had to do to make the recipe work was to change the values of class attributes used in our HTML. This distinction between having to dig into CSS files and being able to simply work with class attributes to alter our layouts is a huge part of the initial success of Bootstrap and the reason why it became such a success.

Get Bootstrap 4 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.