mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-02-16 19:41:06 +03:00
Adds UnicodeJSONRenderer which doesn't ensure ascii
This commit is contained in:
parent
c69f960066
commit
97f034e3d6
|
@ -76,6 +76,10 @@ class JSONRenderer(BaseRenderer):
|
|||
return json.dumps(data, cls=self.encoder_class, indent=indent, ensure_ascii=self.ensure_ascii)
|
||||
|
||||
|
||||
class UnicodeJSONRenderer(JSONRenderer):
|
||||
ensure_ascii = False
|
||||
|
||||
|
||||
class JSONPRenderer(JSONRenderer):
|
||||
"""
|
||||
Renderer which serializes to json,
|
||||
|
|
Loading…
Reference in New Issue
Block a user