git.iko.soy/typeable/servant
on master help sign in
Add multiline Description example
commit262453b0d1d1a90706c9f869e5135cac617ec44f authorCatherine Galkina <catherine@getshoptv.com> dateMon 19 Jun 2017, 16:39 (9 years ago) parent272e47c
1 file changed+8−1
servant/src/Servant/API/Description.hs+8−1
servant/src/Servant/API/Description.hs+8−1
@@ -18,7 +18,14 @@ data Summary (sym :: Symbol)
1818--
1919-- Example:
2020--
21−-- >>> type MyApi = Description "Some longer implementation details here." :> "books" :> Capture "isbn" Text :> Get '[JSON] Book
21+-- >>> :{
22+--type MyApi = Description
23+-- "This comment is visible in multiple Servant interpretations \
24+-- \and can be really long if necessary. \
25+-- \Haskell multiline support is not perfect \
26+-- \but it's still very readable."
27+-- :> Get '[JSON] Book
28+-- :}
2229data Description (sym :: Symbol)
2330 deriving (Typeable)
2431