Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filter out posts that have hidden: true in frontmatter #13

Merged
merged 1 commit into from
Oct 14, 2014
Merged

Filter out posts that have hidden: true in frontmatter #13

merged 1 commit into from
Oct 14, 2014

Conversation

tombell
Copy link
Contributor

@tombell tombell commented Oct 8, 2014

We require the ability to have posts that are available via the URL, but are hidden in the paginated list.

@parkr
Copy link
Member

parkr commented Oct 8, 2014

Seems like a hidden attribute would be for more than just pagination? Also, we have a published element for this already (even if the paginator doesn't track it, it's already honored by Jekyll), right?

@tombell
Copy link
Contributor Author

tombell commented Oct 8, 2014

The blog is "published", it's just hidden from listing. If you don't want to merge, I'll just maintain a fork.

@parkr
Copy link
Member

parkr commented Oct 8, 2014

It's cool, I'm just asking questions, making sure we aren't making lots of ways to do things. What are the properties of a post with hidden: true besides it not being in the paginator?

@tombell
Copy link
Contributor Author

tombell commented Oct 8, 2014

Being filtered out of "lists" mainly

@tombell
Copy link
Contributor Author

tombell commented Oct 8, 2014

I can use where on site.posts, but the paginator generates its own list.

@parkr
Copy link
Member

parkr commented Oct 8, 2014

So it'd still be in site.posts but just not in paginators/sitemap/etc?

@tombell
Copy link
Contributor Author

tombell commented Oct 8, 2014

I use site.posts where: "hidden", nil, but it's includes in paginator.posts so I can't filter it, else I end up with odd post counts on each page.

@parkr
Copy link
Member

parkr commented Oct 8, 2014

Ok so it would just affect already-processed lists like paginator and the list we use to generate the sitemap. Sound right?

@parkr parkr self-assigned this Oct 8, 2014
@tombell
Copy link
Contributor Author

tombell commented Oct 8, 2014

Pretty much.

parkr added a commit that referenced this pull request Oct 14, 2014
@parkr parkr merged commit 076bf13 into jekyll:master Oct 14, 2014
parkr added a commit that referenced this pull request Oct 14, 2014
@parkr
Copy link
Member

parkr commented Oct 14, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants