klugjo / hexo-theme-clean-blog

Hexo implementation of Clean Blog http://blackrockdigital.github.io/startbootstrap-clean-blog/index.html
MIT License
401 stars 129 forks source link

How can I hide some posts at home page #39

Closed zydarChen closed 6 years ago

zydarChen commented 7 years ago

Hi, for some reason, I don't want to show some posts at home page, how can I do it?

klugjo commented 7 years ago

where do you want to show the posts then ?

zydarChen commented 7 years ago

it may be show at Archives or tags/mytag. Because some of the posts for recording something are not ready to be a article at the home pages.

klugjo commented 7 years ago

I don't think this is supported by Hexo. Do you have an example of theme that supports that ?

If you know how to code, you can modify the theme to do that:

in here: https://github.com/klugjo/hexo-theme-clean-blog/blob/master/layout/index.ejs#L21

you need to put a if and check if you want to display or not.

You can check for a property that you will add in the front-matter of your posts

zydarChen commented 7 years ago

OK, I will try it. Thank you so much and like your theme very much!