@hackage Shpadoinkle-backend-static0.2.0.1
A backend for rendering Shpadoinkle as Text.
Categories
License
BSD-3-Clause
Maintainer
isaac.shapira@platonic.systems
Links
- Documentation
- No source repository
- Security
Versions
Installation
Dependencies (4)
- Shpadoinkle
- base >=4.12.0 && <4.16
- compactable >=0.1.2 && <0.2
- text >=1.2.3 && <1.3 Show all…
Dependents (4)
@hackage/Shpadoinkle-router, @hackage/Shpadoinkle-examples, @hackage/Shpadoinkle-disembodied, @hackage/Shpadoinkle-template
Shpadoinkle Backend Static
This module provides a static rendering backend that translates Shpadoinkle Html into Text.
For example:
page :: Html' a
page = h "div" [ ("class", PText "header" ) ]
[ h "h1" [] [ text "Trappers!" ] ]
main = putStrLn $ unpack $ renderStatic page
will output:
<div class="header"><h1>Trappers!</h1></div>