k***@gmail.com
2015-11-27 10:44:05 UTC
Hi,
Thanks for this great project!
I'm having some trouble setting up a page with the following scenario:
1. Create index.html using the the 'create' directive.
2. index.html shows the latest post in full detail.
3. index.html shows links to N latest posts.
This seems straightforward enough, and maybe it is, but I'm having trouble
"injecting" the latest post into the index.html.
Getting the latest posts is pretty easy using "loadAll" and "recentFirst",
but I don't understand how I would inject the $date$, $title$, $body$ from
the latest post etc into the context that's used to apply the template(s).
As far as I understand, the underlying resource is not really there,
because I'm creating index.html not matching against a file, therefore I
have to use makeItem "". Deviating from that results in
The compiler yielded an Item with Identifier
rather than "match"-ed?
Many thanks!
Thanks for this great project!
I'm having some trouble setting up a page with the following scenario:
1. Create index.html using the the 'create' directive.
2. index.html shows the latest post in full detail.
3. index.html shows links to N latest posts.
This seems straightforward enough, and maybe it is, but I'm having trouble
"injecting" the latest post into the index.html.
Getting the latest posts is pretty easy using "loadAll" and "recentFirst",
but I don't understand how I would inject the $date$, $title$, $body$ from
the latest post etc into the context that's used to apply the template(s).
As far as I understand, the underlying resource is not really there,
because I'm creating index.html not matching against a file, therefore I
have to use makeItem "". Deviating from that results in
The compiler yielded an Item with Identifier
notes/2012-12-07-tu-quoque.markdown, but we were expecting an Item with
Identifier index.html (you probably want to call makeItem to solve this
problem)
In short, is there a way to "inject" a post into a page that is "create"-d,Identifier index.html (you probably want to call makeItem to solve this
problem)
rather than "match"-ed?
Many thanks!
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hakyll+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "hakyll" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hakyll+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.