diff options
Diffstat (limited to 'src/Hakyll/Web')
-rw-r--r-- | src/Hakyll/Web/Page.hs | 3 | ||||
-rw-r--r-- | src/Hakyll/Web/Template.hs | 5 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/Hakyll/Web/Page.hs b/src/Hakyll/Web/Page.hs index 220ee29..03995cd 100644 --- a/src/Hakyll/Web/Page.hs +++ b/src/Hakyll/Web/Page.hs @@ -68,6 +68,7 @@ import Data.Ord (comparing) import Hakyll.Core.Identifier import Hakyll.Core.Compiler +import Hakyll.Core.ResourceProvider import Hakyll.Web.Page.Internal import Hakyll.Web.Page.Read import Hakyll.Web.Page.Metadata @@ -90,7 +91,7 @@ toMap (Page m b) = M.insert "body" b m -- | Read a page (do not render it) -- -pageRead :: Compiler a (Page String) +pageRead :: Compiler Resource (Page String) pageRead = getResourceString >>^ readPage -- | Add a number of default metadata fields to a page. These fields include: diff --git a/src/Hakyll/Web/Template.hs b/src/Hakyll/Web/Template.hs index 9ea4183..6e6ad67 100644 --- a/src/Hakyll/Web/Template.hs +++ b/src/Hakyll/Web/Template.hs @@ -58,6 +58,7 @@ import Text.Hamlet (HamletSettings, defaultHamletSettings) import Hakyll.Core.Compiler import Hakyll.Core.Identifier +import Hakyll.Core.ResourceProvider import Hakyll.Web.Template.Internal import Hakyll.Web.Template.Read import Hakyll.Web.Page @@ -85,12 +86,12 @@ applySelf page = applyTemplate (readTemplate $ pageBody page) page -- @.hml@ or @.hamlet@, it will be considered as a Hamlet template, and parsed -- as such. -- -templateRead :: Compiler a Template +templateRead :: Compiler Resource Template templateRead = templateReadWith defaultHamletSettings -- | Version of 'templateRead' that enables custom settings. -- -templateReadWith :: HamletSettings -> Compiler a Template +templateReadWith :: HamletSettings -> Compiler Resource Template templateReadWith settings = getIdentifier &&& getResourceString >>^ uncurry read' where |