Link Search Menu Expand Document

Building contents

Table of contents
  1. Building contents
    1. Create page
    2. Create posts

Create page

We can add post manually by adding new .MD file with the name of the post but there’s a quick way using jekyll-compose plugin.

Install jekyll-compose plugin

Add the following line inside the Gemfile

gem 'jekyll-compose', group:[:jekyll_plugins]

Then in terminal run bundle and this will install this plugin. Then add a post:

bundle exec jekyll page "The title of your page"

this will create the-title-of-your-page.md file, then you can edit it and adjust the Front matter part.

Create posts

We can also create post for blogging if your template has the post layout:

bundle exec jekyll post "Woohoo post"

This will create the 2020-02-20-woohoo-post.md and to check the page, run the serve and URL structure will be /2020/02/20/woohoo-post.html.

You can define the URL structure with categories on the front matter and matched with the layout file.