@@ -156,7 +156,8 @@ We can reproduce a list of items in the archive using the following code:
156156compile $ do
157157 posts <- recentFirst <$> loadAll "posts/*"
158158 itemTpl <- loadBody "templates/post-item.html"
159− applyTemplateList itemTpl postCtx posts
159+ list <- applyTemplateList itemTpl postCtx posts
160+ makeItem list
160161```
161162
162163`recentFirst` sorts items by date. This relies on the convention that posts are
@@ -169,4 +170,5 @@ recentFirst :: [Item a] -> [Item a]
169170
170171After loading and sorting the items, we load a template for the posts.
171172`applyTemplateList` applies this template to every post and concatenates the
172−result, which is a simple `String`.
173+result, which is a simple `String`. After that, we need `makeItem` to wrap the
174+returned `String` to `Item String`.