Search code examples
githubpostrepositoryjekyllblogs

Remove 'blog' section in the Github Jekyll


I am wondering how to use the Github Jekyll website without the 'Blog' section (that includes posts). Could you share your solutions? Thanks in advance.


Solution

  • I'll have to make the assumption that you have a blog page, either blog.html or blog/index.html, and in that page you have a for loop calling site.posts or paginator.posts. You have two options:

    1. Delete the _posts directory.
    2. If you want to keep the posts in _posts but don't want them to display on your site, don't use those for loops mentioned above and you won't see the posts on the frontend.