-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Organized and simple web page scaffold for blaze and lucid -- -- 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" > > ↪ -- "HTMLhtmlheadtitlefoo/title > -- /headbodysome content<script > -- src="jquery.js">/script/body/html" @package webpage @version 0.0.5 module Web.Page.Types -- | Generic layout for a web page. We keep the data type purely parametric -- to allow for record-syntax overloading / reassignment, like this: . -- --
--   page :: WebPage (Html ()) T.Text
--   
-- --
--   page' = page {pageTitle = "foo!"}
--   
data WebPage markup attr attrSet WebPage :: attr -> markup -> markup -> markup -> markup -> markup -> markup -> markup -> attrSet -> WebPage markup attr attrSet -- | Page title [pageTitle] :: WebPage markup attr attrSet -> attr -- | Favicon tags [favicon] :: WebPage markup attr attrSet -> markup -- | <meta> tags [metaVars] :: WebPage markup attr attrSet -> markup -- | JavaScript to include at the top of the page [initScripts] :: WebPage markup attr attrSet -> markup -- | JavaScript to include before <style> tags [beforeStylesScripts] :: WebPage markup attr attrSet -> markup -- | Styles [styles] :: WebPage markup attr attrSet -> markup -- | JavaScript to include after <style> tags - ie: -- Modernizr [afterStylesScripts] :: WebPage markup attr attrSet -> markup -- | JavaScript to include at the base of <body> [bodyScripts] :: WebPage markup attr attrSet -> markup -- | Additional styles to assign to <body> [bodyStyles] :: WebPage markup attr attrSet -> attrSet instance (GHC.Classes.Ord markup, GHC.Classes.Ord attr, GHC.Classes.Ord attrSet) => GHC.Classes.Ord (Web.Page.Types.WebPage markup attr attrSet) instance (GHC.Classes.Eq markup, GHC.Classes.Eq attr, GHC.Classes.Eq attrSet) => GHC.Classes.Eq (Web.Page.Types.WebPage markup attr attrSet) instance (GHC.Show.Show markup, GHC.Show.Show attr, GHC.Show.Show attrSet) => GHC.Show.Show (Web.Page.Types.WebPage markup attr attrSet) instance (GHC.Base.Monoid m, GHC.Base.Monoid a, GHC.Base.Monoid s) => GHC.Base.Monoid (Web.Page.Types.WebPage m a s) instance (GHC.Base.Monoid m, GHC.Base.Monoid a, GHC.Base.Monoid s) => Data.Default.Class.Default (Web.Page.Types.WebPage m a s) module Web.Page.Lucid -- | Generic page template implemented in Lucid. template :: Monad m => WebPage (HtmlT m ()) Text [Attribute] -> HtmlT m () -> HtmlT m () module Web.Page.Blaze -- | You should really be using Lucid... template :: WebPage Html Text Attribute -> Html -> Html module Web.Page.Hastache -- | We choose to not interpolate the WebPage data type as a JSON -- Hastache template value because I don't want the portions of -- WebPage visible by content. template :: WebPage Text Text Text -> Text -> Text