webpage

Organized and simple web page scaffold for blaze and lucid

Version on this page:0.0.5
LTS Haskell 11.22:0.0.5
Stackage Nightly 2018-03-12:0.0.5
Latest on Hackage:0.0.5.1

See all snapshots webpage appears in

MIT licensed and maintained by Athan Clark

Module documentation for 0.0.5

This version can be pinned in stack with:[email protected]:af610555b3f7efb7f26e292140ac8d5f7797a93a0cea319c15c8b46453a356f3,1659

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
   src=\"jquery.js\"></script></body></html>"