From 362d83146cf141b6163d5d0cf502a3a83bd08387 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wojciech=20Moz=CC=87ejko?= Date: Wed, 19 Oct 2016 12:47:34 +0200 Subject: [PATCH] Add support for multiple response codes --- components/documentation/documentation.tag | 4 +- components/method/response.tag | 67 ---------------- components/method/responses.tag | 89 ++++++++++++++++++++++ components/resource/method.tag | 4 +- index.hbs | 11 +++ package.json | 2 +- 6 files changed, 104 insertions(+), 73 deletions(-) delete mode 100644 components/method/response.tag create mode 100644 components/method/responses.tag diff --git a/components/documentation/documentation.tag b/components/documentation/documentation.tag index b89049f..effb2b7 100644 --- a/components/documentation/documentation.tag +++ b/components/documentation/documentation.tag @@ -1,7 +1,7 @@ -
- + +

{ documentation.title() } diff --git a/components/method/response.tag b/components/method/response.tag deleted file mode 100644 index 57651c3..0000000 --- a/components/method/response.tag +++ /dev/null @@ -1,67 +0,0 @@ - - - -
- { JSON.stringify(jsonSchema) } -
- -
- { response.body()[0].example().value() } -
- -
-
- - -
diff --git a/components/method/responses.tag b/components/method/responses.tag new file mode 100644 index 0000000..764c972 --- /dev/null +++ b/components/method/responses.tag @@ -0,0 +1,89 @@ + + + +
+
+ { parseSchema(response.body()[0].schemaContent()) } +
+
+ +
+
+ { response.body()[0].example().value() } +
+
+ +
+
+ + +
diff --git a/components/resource/method.tag b/components/resource/method.tag index c1fa8dc..ab4d264 100644 --- a/components/resource/method.tag +++ b/components/resource/method.tag @@ -7,9 +7,7 @@

- - +
diff --git a/index.hbs b/index.hbs index 05bf30e..de8a513 100644 --- a/index.hbs +++ b/index.hbs @@ -50,8 +50,19 @@