O'Reilly logo

Bootstrap 4 Cookbook by Ajdin Imsirovic

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

How to do it...

  1. Open the folder titled chapter10/start/recipe3 in your Bash.
  2. Some of the files have been added in advance to make the recipe simpler to follow. These files are the four files in the _posts folder. Feel free to copy and paste some of them or alter the contents of the posts in any way you like.
  3. Create a new file inside the _layouts folder called post.html. To do this, type the following command with your console pointing to the root of recipe3 folder:
touch _layouts/post.html
  1. Inside the post.html file, add the following code:
---layout: default-layout---<div class="container"> <div> <h2 class="display-4 mt-5 mb-4">{{ page.title }}</h2> <p class="h3 text-muted mb-4"> By: <em>{{ page.author }}</em>, Published: <em>{{ page.date ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required