Organized and simple web page scaffold for blaze and lucid

Version on this page:0.0.5
LTS Haskell 22.26:
Stackage Nightly 2024-06-19:
Latest on Hackage:

See all snapshots webpage appears in

MIT licensed and maintained by Athan Clark
This version can be pinned in stack with:webpage-0.0.5@sha256:af610555b3f7efb7f26e292140ac8d5f7797a93a0cea319c15c8b46453a356f3,1659

Module documentation for 0.0.5

This is a general organization scheme for web pages, implemented for Lucid, and adapted for Blaze-html.

 import Web.Page.Lucid

 λ> renderText $ template def "some content"

 ↪ "<!DOCTYPE HTML><html><head><title></title><link href
   rel="icon"></head><body>some content</body></html>"

overload the particular areas with record syntax and stuff:

 λ> let page = def { title = "foo"
                   , bodyScripts = script_ [src_ "jquery.js"] ""}

 λ> template page "some content"

 ↪ "<!DOCTYPE HTML><html><head><title>foo</title>
   </head><body>some content<script