Add support for generating snippets in Markdown
This commit introduces support for generating snippets formatted using Markdown. Asciidoctor remains the default. A new SnippetFormat abstraction has been introduced with Asciidoctor and Markdown implementations provided out of the box. Markdown-formatted templates are also provided for all of the default snippets. Please refer to the updated reference documentation for further details. Closes gh-150 Closes gh-19
This commit is contained in:
@@ -0,0 +1,4 @@
|
||||
{{title}}
|
||||
```bash
|
||||
$ curl {{url}} {{options}}
|
||||
```
|
||||
@@ -0,0 +1,8 @@
|
||||
{{title}}
|
||||
```http
|
||||
{{method}} {{path}} HTTP/1.1
|
||||
{{#headers}}
|
||||
{{name}}: {{value}}
|
||||
{{/headers}}
|
||||
{{requestBody}}
|
||||
```
|
||||
@@ -0,0 +1,8 @@
|
||||
{{title}}
|
||||
```http
|
||||
HTTP/1.1 {{statusCode}} {{statusReason}}
|
||||
{{#headers}}
|
||||
{{name}}: {{value}}
|
||||
{{/headers}}
|
||||
{{responseBody}}
|
||||
```
|
||||
@@ -0,0 +1,5 @@
|
||||
Relation | Description | Foo
|
||||
-------- | ----------- | ---
|
||||
{{#links}}
|
||||
{{rel}} | {{description}} | {{foo}}
|
||||
{{/links}}
|
||||
@@ -0,0 +1,6 @@
|
||||
{{title}}
|
||||
Relation | Description
|
||||
-------- | -----------
|
||||
{{#links}}
|
||||
{{rel}} | {{description}}
|
||||
{{/links}}
|
||||
@@ -0,0 +1,5 @@
|
||||
Parameter | Description | Foo
|
||||
--------- | ----------- | ---
|
||||
{{#parameters}}
|
||||
{{name}} | {{description}} | {{foo}}
|
||||
{{/parameters}}
|
||||
@@ -0,0 +1,6 @@
|
||||
{{title}}
|
||||
Parameter | Description
|
||||
--------- | -----------
|
||||
{{#parameters}}
|
||||
{{name}} | {{description}}
|
||||
{{/parameters}}
|
||||
@@ -0,0 +1,5 @@
|
||||
Path | Type | Description | Foo
|
||||
---- | ---- | ----------- | ---
|
||||
{{#fields}}
|
||||
{{path}} | {{type}} | {{description}} | {{foo}}
|
||||
{{/fields}}
|
||||
@@ -0,0 +1,6 @@
|
||||
{{title}}
|
||||
Path | Type | Description
|
||||
---- | ---- | -----------
|
||||
{{#fields}}
|
||||
{{path}} | {{type}} | {{description}}
|
||||
{{/fields}}
|
||||
@@ -0,0 +1,5 @@
|
||||
Name | Description | Foo
|
||||
---- | ----------- | ---
|
||||
{{#headers}}
|
||||
{{name}} | {{description}} | {{foo}}
|
||||
{{/headers}}
|
||||
@@ -0,0 +1,6 @@
|
||||
{{title}}
|
||||
Name | Description
|
||||
---- | -----------
|
||||
{{#headers}}
|
||||
{{name}} | {{description}}
|
||||
{{/headers}}
|
||||
@@ -0,0 +1,5 @@
|
||||
Parameter | Description | Foo
|
||||
--------- | ----------- | ---
|
||||
{{#parameters}}
|
||||
{{name}} | {{description}} | {{foo}}
|
||||
{{/parameters}}
|
||||
@@ -0,0 +1,6 @@
|
||||
{{title}}
|
||||
Parameter | Description
|
||||
--------- | -----------
|
||||
{{#parameters}}
|
||||
{{name}} | {{description}}
|
||||
{{/parameters}}
|
||||
@@ -0,0 +1,5 @@
|
||||
Path | Type | Description | Foo
|
||||
---- | ---- | ----------- | ---
|
||||
{{#fields}}
|
||||
{{path}} | {{type}} | {{description}} | {{foo}}
|
||||
{{/fields}}
|
||||
@@ -0,0 +1,6 @@
|
||||
{{title}}
|
||||
Path | Type | Description
|
||||
---- | ---- | -----------
|
||||
{{#fields}}
|
||||
{{path}} | {{type}} | {{description}}
|
||||
{{/fields}}
|
||||
@@ -0,0 +1,5 @@
|
||||
Name | Description | Foo
|
||||
---- | ----------- | ---
|
||||
{{#headers}}
|
||||
{{name}} | {{description}} | {{foo}}
|
||||
{{/headers}}
|
||||
@@ -0,0 +1,6 @@
|
||||
{{title}}
|
||||
Name | Description
|
||||
---- | -----------
|
||||
{{#headers}}
|
||||
{{name}} | {{description}}
|
||||
{{/headers}}
|
||||
Reference in New Issue
Block a user