Route middleware for wai.
It's Heavy inspired by vhost
middleware from wai-extra
but
gives some sugar to life.
- dispatch :: [(Request -> Bool, Application)] -> Application -> Application
- rule :: Method -> ByteString -> Request -> Bool
Dispatching
:: [(Request -> Bool, Application)] | List of routes |
-> Application | Default |
-> Application | Returns founded |