diff options
| author | Carlton Gibson | 2014-04-15 15:13:51 +0200 |
|---|---|---|
| committer | Carlton Gibson | 2014-04-15 15:13:51 +0200 |
| commit | c93ddf1750267f9145cbea556deb412fa5b7123e (patch) | |
| tree | 6f642c087569447d000a0e02c0290f5bcad05b41 /docs/api-guide/renderers.md | |
| parent | b3b0515ae6325e7de6a582bbb2fd7eeac687c325 (diff) | |
| parent | 617c9825913cfc0cdeaa4405df0b885db0a9ff60 (diff) | |
| download | django-rest-framework-c93ddf1750267f9145cbea556deb412fa5b7123e.tar.bz2 | |
Merge pull request #1520 from hroncok/patch-2
Allow unicode YAML dump
Diffstat (limited to 'docs/api-guide/renderers.md')
| -rw-r--r-- | docs/api-guide/renderers.md | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/docs/api-guide/renderers.md b/docs/api-guide/renderers.md index 7798827b..7a3429bf 100644 --- a/docs/api-guide/renderers.md +++ b/docs/api-guide/renderers.md @@ -138,6 +138,26 @@ Renders the request data into `YAML`. Requires the `pyyaml` package to be installed. +Note that non-ascii characters will be rendered using `\uXXXX` character escape. For example: + + unicode black star: "\u2605" + +**.media_type**: `application/yaml` + +**.format**: `'.yaml'` + +**.charset**: `utf-8` + +## UnicodeYAMLRenderer + +Renders the request data into `YAML`. + +Requires the `pyyaml` package to be installed. + +Note that non-ascii characters will not be character escaped. For example: + + unicode black star: ★ + **.media_type**: `application/yaml` **.format**: `'.yaml'` |
