How it works…

There is a lot of code in this recipe. Some of this code is repetitive. To make the code both easier to understand (since there is so much of it) and easier to work with (for example, we could decide later on to alter or replace the cards in the recipe), we have separated our code into partials.

Step 1 started with the main recipe file, which consists of four sections--four partial files:

  • The top-most section of the recipe, which holds the recipe title and a short explanation in a couple of paragraphs
  • The style tag partial, which holds our recipe-specific CSS
  • The third partial file holds the markup for the actual nav-tabs, that is, the nav tab menu itself
  • The fourth partial file has the actual content for each of the tabs

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.