The scotty package
A Haskell web framework inspired by Ruby's Sinatra, using WAI and Warp.
{-# LANGUAGE OverloadedStrings #-}
import Web.Scotty
import Data.Monoid (mconcat)
main = scotty 3000 $ do
get "/:word" $ do
beam <- param "word"
html $ mconcat ["<h1>Scotty, ", beam, " me up!</h1>"]
Scotty is the cheap and cheerful way to write RESTful, declarative web applications.
A page is as simple as defining the verb, url pattern, and Text content.
It is template-language agnostic. Anything that returns a Text value will do.
Conforms to WAI Application interface.
Uses very fast Warp webserver by default.
As for the name: Sinatra + Warp = Scotty.
Properties
| Versions | 0.0.1, 0.1.0, 0.2.0, 0.3.0, 0.4.0, 0.4.1, 0.4.2, 0.4.3, 0.4.4, 0.4.5, 0.4.6 |
|---|---|
| Dependencies | aeson (≥0.6.0.2), base (≥4.3.1 & <5), blaze-builder (≥0.3.1.0), bytestring (≥0.9.1), case-insensitive (≥0.4.0.3), conduit (≥0.5.2.7), data-default (≥0.5.0), http-types (≥0.7.3.0.1), mtl (≥2.1.2), regex-compat (≥0.95.1), resourcet (≥0.4.0.2), text (≥0.11.2.3), wai (≥1.3.0.1), wai-extra (≥1.3.0.3), warp (≥1.3.4.1) |
| License | BSD3 |
| Copyright | (c) 2012 Andrew Farmer |
| Author | Andrew Farmer <anfarmer@ku.edu> |
| Maintainer | Andrew Farmer <anfarmer@ku.edu> |
| Stability | experimental |
| Category | Web |
| Home page | https://github.com/ku-fpg/scotty |
| Bug tracker | https://github.com/ku-fpg/scotty/issues |
| Source repository | git clone git://github.com/ku-fpg/scotty.git |
| Upload date | Thu Oct 25 21:54:53 UTC 2012 |
| Uploaded by | AndrewFarmer |
| Built on | ghc-7.6 |
| Distributions | NixOS: 0.4.6 |
Modules
- Web
Downloads
- scotty-0.4.6.tar.gz (Cabal source package)
- package description (included in the package)