Skip to main content

Documentation Utilities (Docutils, reStructuredText) for django.

Project description

Python Package Documentation Status Build Status Code Coverage License

django-docutils, docutils (reStructuredText) support for Django


The full documentation is at


Install django-docutils:

pip install django-docutils

Template filter

If you want to use the template filter, add it to your INSTALLED_APPS in your settings file:

INSTALLED_APPS = [ # ... your default apps,

Then in your template:

{% load django_docutils %}
{% filter restructuredtext %}
# hey
# how's it going
A. hows
B. it

C. going
D. today

{% endfilter %}

Template engine (class-based view)

You can also use a class-based view to render restructuredtext.

If you want to use reStructuredText as a django template engine, INSTALLED_APPS isn’t required, instead you add this to your TEMPLATES variable in your settings:

TEMPLATES = [ # .. your default engines
    'NAME': 'docutils',
    'BACKEND': 'django_docutils.engines.Docutils',
    'DIRS': [],
    'APP_DIRS': True,

Now django will be able to scan for .rst files and process them. In your view:

from django_docutils.views import DocutilsView

class HomeView(DocutilsView):
    template_name = 'base.html'
    rst_name = 'home.rst'

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
django-docutils-0.4.0.tar.gz (8.5 kB) Copy SHA256 hash SHA256 Source None

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page