Merge pull request #1043 from rsoeldner/fix-markdown

Fix markdown indentation and compilation warning
This commit is contained in:
Oleg Grenrus 2018-10-31 18:50:21 +02:00 committed by GitHub
commit 58ccae1ca0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 30 additions and 34 deletions

View file

@ -10,34 +10,42 @@ You'll also note that multiple intros are possible.
## POST /greet ## POST /greet
#### Request: ### Request:
- Supported content types are: - Supported content types are:
- `application/json;charset=utf-8`
- `application/json` - `application/json`
- Example: `application/json` - If you use ?capital=true (`application/json;charset=utf-8`, `application/json`):
```javascript ```javascript
"HELLO, HASKELLER" "HELLO, HASKELLER"
``` ```
#### Response: - If you use ?capital=false (`application/json;charset=utf-8`, `application/json`):
- Status code 201 ```javascript
"Hello, haskeller"
```
### Response:
- Status code 200
- Headers: [("X-Example","1729")] - Headers: [("X-Example","1729")]
- Supported content types are: - Supported content types are:
- `application/json;charset=utf-8`
- `application/json` - `application/json`
- If you use ?capital=true - If you use ?capital=true (`application/json;charset=utf-8`, `application/json`):
```javascript ```javascript
"HELLO, HASKELLER" "HELLO, HASKELLER"
``` ```
- If you use ?capital=false - If you use ?capital=false (`application/json;charset=utf-8`, `application/json`):
```javascript ```javascript
"Hello, haskeller" "Hello, haskeller"
@ -45,81 +53,70 @@ You'll also note that multiple intros are possible.
## DELETE /greet/:greetid ## DELETE /greet/:greetid
#### Title ### Title
This is some text This is some text
#### Second secton ### Second secton
And some more And some more
#### Captures: ### Captures:
- *greetid*: identifier of the greet msg to remove - *greetid*: identifier of the greet msg to remove
### Headers:
- This endpoint is sensitive to the value of the **unicorns** HTTP header. - This endpoint is sensitive to the value of the **unicorns** HTTP header.
#### Response: ### Response:
- Status code 200 - Status code 200
- Headers: [] - Headers: []
- Supported content types are: - Supported content types are:
- `application/json;charset=utf-8`
- `application/json` - `application/json`
- Response body as below. - Example (`application/json;charset=utf-8`, `application/json`):
```javascript ```javascript
[]
``` ```
## GET /hello/:name ## GET /hello/:name
#### Captures: ### Captures:
- *name*: name of the person to greet - *name*: name of the person to greet
#### GET Parameters: ### GET Parameters:
- capital - capital
- **Values**: *true, false* - **Values**: *true, false*
- **Description**: Get the greeting message in uppercase (true) or not (false).Default is false. - **Description**: Get the greeting message in uppercase (true) or not (false).Default is false.
#### Response: ### Response:
- Status code 200 - Status code 200
- Headers: [] - Headers: []
- Supported content types are: - Supported content types are:
- `application/json;charset=utf-8`
- `application/json` - `application/json`
- `text/plain;charset=utf-8` - `text/plain;charset=utf-8`
- If you use ?capital=true - If you use ?capital=true (`application/json;charset=utf-8`, `application/json`, `text/plain;charset=utf-8`):
```javascript ```javascript
"HELLO, HASKELLER" "HELLO, HASKELLER"
``` ```
- If you use ?capital=true - If you use ?capital=false (`application/json;charset=utf-8`, `application/json`):
```
"HELLO, HASKELLER"
```
- If you use ?capital=false
```javascript ```javascript
"Hello, haskeller" "Hello, haskeller"
``` ```
- If you use ?capital=false
```
"Hello, haskeller"
```

View file

@ -760,9 +760,9 @@ markdownWith RenderingOptions{..} api = unlines $
contentStr mime_type body = contentStr mime_type body =
"" : "" :
" ```" <> markdownForType mime_type : "```" <> markdownForType mime_type :
cs body : cs body :
" ```" : "```" :
"" : "" :
[] []
@ -866,7 +866,6 @@ instance {-# OVERLAPPABLE #-}
t = Proxy :: Proxy '[ct] t = Proxy :: Proxy '[ct]
method' = reflectMethod (Proxy :: Proxy method) method' = reflectMethod (Proxy :: Proxy method)
status = fromInteger $ natVal (Proxy :: Proxy status) status = fromInteger $ natVal (Proxy :: Proxy status)
p = Proxy :: Proxy a
instance {-# OVERLAPPING #-} instance {-# OVERLAPPING #-}
(ToSample a, AllMimeRender (ct ': cts) a, KnownNat status (ToSample a, AllMimeRender (ct ': cts) a, KnownNat status