skip to Main Content

So I faced a problem while trying to add some SEO optimization for my simple static website served via Github Pages.

As the documentation says: https://help.github.com/articles/search-engine-optimization-for-github-pages/

I created the _config.yml file which includes next lines of code:

plugins:
  - jekyll-seo-tag

and pushed this file along with my website files, so the structure looks like this

The problem is that after linking to my website I see the
output

And the head tag includes following content

I need help in understanding why the SEO plugin doesn’t work. Thanks for all your replies and have a nice day!

2

Answers


  1. Chosen as BEST ANSWER

    David Jacquel's answer helped so much and I managed to resolve a problem. More about that:

    I had to inject a valid front matter to resolve a problem e.g.

    ---
      layout: main
      title: Cheaterino
    ---
    

    After that I still didn't manage to deal with the problem since my index.html was minified and so do the front matter.

    After I disabled minification of the file everything worked!

    head tag content after plugin worked

    Thanks so much to David Jacquel!


  2. If you want any file to be processed you must add a front matter to it.

    Your index.html must be like :

    ---
    # even an empty front matter is ok
    ---
    <!DOCTYPE html>
    ...
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search