Added a comment explaining "teaserContext" function.
This commit is contained in:
parent
2651627189
commit
9ad0d38f43
1 changed files with 3 additions and 0 deletions
|
@ -92,6 +92,9 @@ defaultContext =
|
|||
missingField
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
-- | A context with "teaser" key which contain a teaser of the item.
|
||||
-- The item is loaded from the given snapshot (which should be saved
|
||||
-- in the user code before any templates are applied).
|
||||
teaserContext :: Snapshot -> Context String
|
||||
teaserContext snapshot = field "teaser" $ \item ->
|
||||
(needlePrefix teaserSeparator . itemBody) <$>
|
||||
|
|
Loading…
Reference in a new issue