From 5169f54d70a21a2fe462148cbe0b931eee0b8849 Mon Sep 17 00:00:00 2001 From: Akhil Date: Fri, 6 Mar 2020 13:40:36 +0530 Subject: [PATCH] Update documentation to mention support for Django 1.11. --- docs/installation.rst | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/docs/installation.rst b/docs/installation.rst index 52f2520..048a994 100644 --- a/docs/installation.rst +++ b/docs/installation.rst @@ -8,7 +8,7 @@ Requirements Graphene-Django currently supports the following versions of Django: -* Django 2.X +* >= Django 1.11 Installation ------------ @@ -32,6 +32,20 @@ Add ``graphene_django`` to the ``INSTALLED_APPS`` in the ``settings.py`` file of We need to add a ``graphql`` URL to the ``urls.py`` of your Django project: +For Django 1.11: + +.. code:: python + + from django.conf.urls import url + from graphene_django.views import GraphQLView + + urlpatterns = [ + # ... + url(r"graphql", GraphQLView.as_view(graphiql=True)), + ] + +For Django 2.0 and above: + .. code:: python from django.urls import path