Variable in front matter


Hello, today I started my journey to learn jekyll, unfortunately I already found a difficulty that I could not overcome.
I created a new project and copied the files and folders from Minima to the main project folder. I was adding a variable in home.html like so:

layout: default
title: My Title

I tried to use it in the Home file (Not yet changed by me) like this:
<h1> {{page.title}} </ h1>

But he did not appear. What am I doing wrong?

Then I called:
<h1> {{page.layout}} </ h1>
to my surprise it worked, and wrote Home, I saw that it picked up from the file. But this file says I should not edit it.


The home file looks like a layout file used on the home page (I don’t use minima). If you look at the file there is no title - that is probably why it didn’t show up.

If you want to make sure, go to the file and add title: my title to the front matter just to see if it works.

I’m guessing the theme is using something from the config file to do the title.