mirror of
https://github.com/graphql-python/graphene-django.git
synced 2024-11-14 05:37:02 +03:00
6b8c5bdefc
* don't replace <body> * Update graphene_django/templates/graphene/graphiql.html Co-Authored-By: Jonathan Kim <jkimbo@gmail.com> * Fix editor styling and initialisation Co-authored-by: Jonathan Kim <jkimbo@gmail.com>
39 lines
1.4 KiB
HTML
39 lines
1.4 KiB
HTML
<!--
|
|
The request to this GraphQL server provided the header "Accept: text/html"
|
|
and as a result has been presented GraphiQL - an in-browser IDE for
|
|
exploring GraphQL.
|
|
If you wish to receive JSON, provide the header "Accept: application/json" or
|
|
add "&raw" to the end of the URL within a browser.
|
|
-->
|
|
{% load static %}
|
|
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<style>
|
|
html, body, #editor {
|
|
height: 100%;
|
|
margin: 0;
|
|
overflow: hidden;
|
|
width: 100%;
|
|
}
|
|
</style>
|
|
<link href="https://cdn.jsdelivr.net/npm/graphiql@{{graphiql_version}}/graphiql.css"
|
|
rel="stylesheet"
|
|
crossorigin="anonymous" />
|
|
<script src="https://cdn.jsdelivr.net/npm/whatwg-fetch@2.0.3/fetch.min.js"
|
|
integrity="sha384-dcF7KoWRaRpjcNbVPUFgatYgAijf8DqW6NWuqLdfB5Sb4Cdbb8iHX7bHsl9YhpKa"
|
|
crossorigin="anonymous"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/react@{{react_version}}/umd/react.production.min.js"
|
|
crossorigin="anonymous"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/react-dom@{{react_version}}/umd/react-dom.production.min.js"
|
|
crossorigin="anonymous"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/graphiql@{{graphiql_version}}/graphiql.min.js"
|
|
crossorigin="anonymous"></script>
|
|
</head>
|
|
<body>
|
|
<div id="editor"></div>
|
|
{% csrf_token %}
|
|
<script src="{% static 'graphene_django/graphiql.js' %}"></script>
|
|
</body>
|
|
</html>
|