on master help sign in
Add applyTemplateCompiler
commit7aac6ccd5dfc635ad77bc74781ab06b0b1b9fe5e authorJasper Van der Jeugt <jaspervdj@gmail.com> dateFri 18 Feb 2011, 18:15 (16 years ago) parent03fb17e
1 file changed+5
src/Hakyll/Web/Template.hs+5
src/Hakyll/Web/Template.hs+5
@@ -47,6 +47,7 @@ module Hakyll.Web.Template
4747 , applySelf
4848 , templateCompiler
4949 , templateCompilerWith
50+ , applyTemplateCompiler
5051 ) where
5152
5253import Control.Arrow
@@ -102,3 +103,7 @@ templateCompilerWith settings =
102103 then readHamletTemplateWith settings string
103104 -- Hakyll template
104105 else readTemplate string
106+
107+applyTemplateCompiler :: Identifier -- ^ Template
108+ -> Compiler (Page String) (Page String) -- ^ Compiler
109+applyTemplateCompiler identifier = require identifier (flip applyTemplate)