Jekyll: Publish but don't include in blog front page or archive

Created on 28 May 2017  路  2Comments  路  Source: jekyll/jekyll

  • [x] This is a feature request.

I would like an option that generates the blog article but does not include it in the blog front page or archive. One possible implementation extends the front matter key published

published: hidden
frozen-due-to-age

Most helpful comment

Hope useful:

{% for p in site.posts %}
{% if p.published !="hidden" %}
{{p.title}}
{% endif %}
{% endfor %}

All 2 comments

Hope useful:

{% for p in site.posts %}
{% if p.published !="hidden" %}
{{p.title}}
{% endif %}
{% endfor %}

As @KeJunMao kindly shows in the example above, you can filter posts on a particular value of a front-matter variable. Could be hidden: true or whatever you want.

Was this page helpful?
0 / 5 - 0 ratings