From 4f0a2b78a32242f50406fd26503e510ca015d1d5 Mon Sep 17 00:00:00 2001 From: Austin Marino <32184751+austinmm@users.noreply.github.com> Date: Sun, 13 Oct 2019 11:45:33 -0700 Subject: [PATCH] Updated Format description layout --- docs/plugins/export.rst | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/docs/plugins/export.rst b/docs/plugins/export.rst index ea2624094..0a27c101b 100644 --- a/docs/plugins/export.rst +++ b/docs/plugins/export.rst @@ -48,25 +48,28 @@ Configuration To configure the plugin, make a ``export:`` section in your configuration file. Under the ``json``, ``csv``, and ``xml`` keys, these options are available: -- **ensure_ascii**: Escape non-ASCII characters with ``\uXXXX`` entities. +- **JSON Formatting** + - **ensure_ascii**: Escape non-ASCII characters with ``\uXXXX`` entities. -- **indent**: The number of spaces for indentation. + - **indent**: The number of spaces for indentation. -- **separators**: A ``[item_separator, dict_separator]`` tuple. + - **separators**: A ``[item_separator, dict_separator]`` tuple. -- **sort_keys**: Sorts the keys in JSON dictionaries. + - **sort_keys**: Sorts the keys in JSON dictionaries. -- **delimiter**: Used as the separating character between fields. The default value is a comma (,). +- **CSV Formatting** + - **delimiter**: Used as the separating character between fields. The default value is a comma (,). -- **dialect**: A dialect, in the context of reading and writing CSVs, is a construct that allows you to create, store, and re-use various formatting parameters for your data. + - **dialect**: A dialect, in the context of reading and writing CSVs, is a construct that allows you to create, store, and re-use various formatting parameters for your data. -- **encoding**: Use encoding="unicode" to generate a Unicode string (otherwise, a bytestring is generated). +- **XML Formatting** + - **encoding**: Use encoding="unicode" to generate a Unicode string (otherwise, a bytestring is generated). -- **xml_declaration**: Controls if an XML declaration should be added to the file. Use False for never, True for always, None for only if not US-ASCII or UTF-8 or Unicode (default is None). + - **xml_declaration**: Controls if an XML declaration should be added to the file. Use False for never, True for always, None for only if not US-ASCII or UTF-8 or Unicode (default is None). -- **method**: Can be either "xml", "html" or "text" (default is "xml") + - **method**: Can be either "xml", "html" or "text" (default is "xml") -- **short_empty_elements**: Controls the formatting of elements that contain no content. If True (the default), they are emitted as a single self-closed tag, otherwise they are emitted as a pair of start/end tags. + - **short_empty_elements**: Controls the formatting of elements that contain no content. If True (the default), they are emitted as a single self-closed tag, otherwise they are emitted as a pair of start/end tags. These options match the options from the `Python json module`_.