Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Ihor Kaharlichenko
swagger-ui-oms
Commits
5f4eec1b
Commit
5f4eec1b
authored
Aug 28, 2013
by
tomrac87
Browse files
Added proper formatting for hal+json Content-Type responses
parent
f22efb66
Changes
1
Hide whitespace changes
Inline
Side-by-side
dist/swagger-ui.js
View file @
5f4eec1b
...
...
@@ -1673,7 +1673,7 @@ helpers = this.merge(helpers, Handlebars.helpers); data = data || {};
if
(
content
===
void
0
)
{
code
=
$
(
'
<code />
'
).
text
(
"
no content
"
);
pre
=
$
(
'
<pre class="json" />
'
).
append
(
code
);
}
else
if
(
contentType
.
indexOf
(
"
application/json
"
)
===
0
)
{
}
else
if
(
contentType
.
indexOf
(
"
application/json
"
)
===
0
||
contentType
.
indexOf
(
"
application/hal+json
"
)
===
0
)
{
code
=
$
(
'
<code />
'
).
text
(
JSON
.
stringify
(
JSON
.
parse
(
content
),
null
,
2
));
pre
=
$
(
'
<pre class="json" />
'
).
append
(
code
);
}
else
if
(
contentType
.
indexOf
(
"
application/xml
"
)
===
0
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment