mirror of
https://github.com/jupyterhub/jupyterhub.git
synced 2025-10-16 06:22:59 +00:00
address djlint lint
and autoformat js in templates
This commit is contained in:
@@ -19,14 +19,18 @@
|
||||
{%- block content %}
|
||||
<redoc id="redoc-spec"></redoc>
|
||||
<script>
|
||||
if (location.protocol === "file:") {
|
||||
document.body.innerText = "Rendered API specification doesn't work with file: protocol. Use sphinx-autobuild to do local builds of the docs, served over HTTP."
|
||||
} else {
|
||||
Redoc.init(
|
||||
"{{ pathto('_static/rest-api.yml', 1) }}",
|
||||
{{ meta.redoc_options | default({}) }},
|
||||
document.getElementById("redoc-spec"),
|
||||
);
|
||||
}
|
||||
if (location.protocol === "file:") {
|
||||
document.body.innerText = "Rendered API specification doesn't work with file: protocol. Use sphinx-autobuild to do local builds of the docs, served over HTTP."
|
||||
} else {
|
||||
Redoc.init(
|
||||
"{{ pathto('_static/rest-api.yml', 1) }}", {
|
||||
{
|
||||
meta.redoc_options |
|
||||
default ({})
|
||||
}
|
||||
},
|
||||
document.getElementById("redoc-spec"),
|
||||
);
|
||||
}
|
||||
</script>
|
||||
{%- endblock content %}
|
||||
|
Reference in New Issue
Block a user