GitXplorerGitXplorer
m

django-rest-framework-orjson

public
14 stars
2 forks
1 issues

Commits

List of commits on branch master.
Unverified
875fd4937b188145c2e15edbd321a8bb2423069d

chore: Bump version

mmauricioabreu committed 5 years ago
Unverified
4945cd21e33de338b1a8c26f7b55ea4cfb1d5afb

fix: Forgot to import codecs

hhongquan committed 6 years ago
Unverified
0dc276b815f8ee7acff5810538553560e1dbe44d

chore: Bump version

mmauricioabreu committed 6 years ago
Unverified
661609022c3d161dea2d45ccda7cc64e0ba68b45

docs: Fix package name on example

mmauricioabreu committed 6 years ago
Unverified
4148058a8618b68530432b79ee39350079506fb4

test: Fix tests using the right parser/renderer

mmauricioabreu committed 6 years ago
Unverified
17dd2cad0e94f201d15c247ec06e40e36e631930

chore: Bump version

mmauricioabreu committed 6 years ago

README

The README file for this repository.

djangorestframework-orjson

|build-status-image| |pypi-version|

Overview

Provides parser and renderer support for orjson library

Requirements

  • Python (3.5, 3.6, 3.7)
  • Django (1.11, 2.0, 2.1)
  • Django REST Framework (3.6, 3.7, 3.8, 3.9)

Installation

Install using pip\ …

.. code:: bash

$ pip install djangorestframework-orjson

Example

You can use this library by adding the following lines to your settings file:

.. code:: python

REST_FRAMEWORK = {
    'DEFAULT_RENDERER_CLASSES': (
        'rest_framework_orjson.renderers.ORJSONRenderer',
    ),
    'DEFAULT_PARSER_CLASSES': (
        'rest_framework_orjson.parsers.ORJSONParser',
    ),
}

Testing

Install testing requirements.

.. code:: bash

$ pip install -r requirements.txt

Run with runtests.

.. code:: bash

$ ./runtests.py

You can also use the excellent tox_ testing tool to run the tests against all supported versions of Python and Django. Install tox globally, and then simply run:

.. code:: bash

$ tox

.. _tox: http://tox.readthedocs.org/en/latest/

.. |build-status-image| image:: https://secure.travis-ci.org/mauricioabreu/django-rest-framework-orjson.svg?branch=master :target: http://travis-ci.org/mauricioabreu/django-rest-framework-orjson?branch=master .. |pypi-version| image:: https://img.shields.io/pypi/v/djangorestframework-orjson.svg :target: https://pypi.python.org/pypi/djangorestframework-orjson