Skip to main content
Warning: You are using the test version of PyPI. This is a pre-production deployment of Warehouse. Changes made here affect the production instance of TestPyPI (testpypi.python.org).
Help us improve Python packaging - Donate today!

Simple JSONP support for django

Project Description
# django-jsonp
Simple JSONP support for django

[![Coverage Status](https://coveralls.io/repos/ZhukovAlexander/django-jsonp/badge.svg?branch=master&service=github)](https://coveralls.io/github/ZhukovAlexander/django-jsonp?branch=master)
[![Build Status](https://travis-ci.org/ZhukovAlexander/django-jsonp.svg)](https://travis-ci.org/ZhukovAlexander/django-jsonp)
## Installation

Install using `pip`...

```bash
$ pip install git+https://github.com/ZhukovAlexander/django-jsonp#egg=django_jsonp
```

## Usage

```python
from djsonp import jsonp, JSONPResponse, get_callback

# decorate something that returns a dict-like object
@jsonp
def my_view(request):
return {'foo': 'bar'}


# it can work with an HttpResponse instances
@jsonp
def another_view(request):
return HttpResponse("{'foo': 'bar'}")

# or just return a JSONPResponse
def jsonp_view(request):
return JSONPResponse(data={'foo': 'bar', }, callback=get_callback(request))
```
Release History

Release History

History Node

1.2.3.dev1

History Node

1.2.2.dev1

History Node

1.2.1.dev1

History Node

1.2.0.dev1

This version
History Node

0.2

Download Files

Download Files

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

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
django_jsonp-0.2.tar.gz (2.6 kB) Copy SHA256 Checksum SHA256 Source Sep 9, 2015

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting