Closed zalun closed 10 years ago
That's good idea. What if we implement it that way: every page which has draft: true
will not be returned by this.pages
.
exactly what I suggested :) https://github.com/zalun/zalun.github.io/blob/master/articles/pianostairs.md
I've been lame and modified https://github.com/zalun/zalun.github.io/blob/master/lib/list.techy.js#L7 BTW is there a way to add default values with get - where to look for docs?
Ok, great. I'll implement the draft
property as you suggested. The get
method is defined here. What you mean by default value? A value which is set to all the pages automatically?
Yes, system throws errors when a) too many pages are requested b) tags, preface or date is not provided title defaults to "techy" so it's build in.
Yep, you are right. This is a must-have feature, so goes on the top of my list.
I just realized that there is a way to define variables for all the pages: http://krasimir.github.io/techy/docs/#master-config Is that working for you?
Yes - cool - I'll do it there
Ok, let me know if that works in your case.
It's done. The new 0.0.44
version supports that feature. Here is the test case https://github.com/krasimir/techy/tree/master/tests/draft-pages
For example, a page containing the following code will be compiled but not returned by the pages
method:
---
title: C page
draft: yes
---
# C page
It would be good to have a draft pages These would live, be rendered, but not returned via
this.pages(...)