waitra

A very simple Wai router https://github.com/futurice/waitra

Version on this page:0.0.3.0
LTS Haskell 8.2:0.0.4.0
Stackage Nightly 2017-02-25:0.0.4.0
Latest on Hackage:0.0.4.0
MIT licensed and maintained by Oleg Grenrus

Module documentation for 0.0.3.0

There are no documented modules for this package.

Waitra

Waitra is a very simple router. It's useful for writing simple API web-services, when you don't want to use the whole Yesod stack.

Build Status

Synopsis

echoRoute :: Route
echoRoute = routeGet (echoApp <$ string "/api/echo/" <*> many anySym)
  where echoApp msg _req respond = respond $ responseLBS status200 [] (fromString msg)

app :: Application
app = waitraMiddleware [echoRoute] $ staticApp $ embeddedSettings $(mkRecursiveEmbedded "static")

Documentation

Documentation is available at hackage.

comments powered byDisqus