Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Class Based Views backported from Django trunk

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 cbv
Octocat-spinner-32 diffs
Octocat-spinner-32 .gitignore
Octocat-spinner-32 LICENSE
Octocat-spinner-32 MANIFEST.in
Octocat-spinner-32 README.rst
Octocat-spinner-32 setup.py
README.rst

Django Class Based Views

This is Django Class Based Views taken from Django trunk.

Use CBVs like this:

import cbv as generic

Then write your class-based views as expained in the Django documentation:

class SomeView(generic.TemplateView):
    template_name = 'some_template.html'

You will need the following middleware installed:

cbv.middleware.DeferredRenderingMiddleware

Once you're ready to use Django 1.3, you'll only need to switch the import statement to:

from django.views import generic
Something went wrong with that request. Please try again.