[英]Remove 'blog' section in the Github Jekyll
I am wondering how to use the Github Jekyll website without the 'Blog' section (that includes posts).我想知道如何在没有“博客”部分(包括帖子)的情况下使用 Github Jekyll 网站。 Could you share your solutions?
你能分享你的解决方案吗? Thanks in advance.
提前致谢。
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
.我必须假设您有一个博客页面,
blog.html
或blog/index.html
,并且在该页面中有一个for
循环调用site.posts
或paginator.posts
。 You have two options:你有两个选择:
_posts
directory._posts
目录。_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._posts
中但不希望它们显示在您的网站上,请不要使用上面提到的那些for
循环,您将不会在前端看到帖子。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.