@hackage twain1.0.0.0

Tiny web application framework for WAI.

Twain

Hackage BSD3 License

Twain is a tiny web application framework for WAI.

  • Simple routing with path captures.
  • Parameter parsing of cookies, path, query, and body.
  • Compose responses from an app environment using a reader-like monad.
  • Helpers for redirects, headers, status codes.
  • Routes decompose into WAI middleware.
import Web.Twain

main :: IO ()
main = do
  twain 8080 "my app" $ do
    get "/" $ do
      send $ html "Hello, World!"