From dee520fc4605c6be16f96d43a9ecb2fd3f5e715b Mon Sep 17 00:00:00 2001 From: Andrew Davis Date: Wed, 11 Apr 2018 13:39:09 -0700 Subject: [PATCH] Add some additional rendering options from xmlbuilder to the documentation See https://github.com/oozcitak/xmlbuilder-js/wiki#converting-to-string --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index be7b83f4..f551ea4e 100644 --- a/README.md +++ b/README.md @@ -333,11 +333,13 @@ Possible options are: * `rootName` (default `root` or the root key name): root element name to be used in case `explicitRoot` is `false` or to override the root element name. - * `renderOpts` (default `{ 'pretty': true, 'indent': ' ', 'newline': '\n' }`): + * `renderOpts` (default `{ 'pretty': true, 'indent': ' ', 'newline': '\n', 'allowEmpty': false, 'spacebeforeslash': '' }`): Rendering options for xmlbuilder-js. * pretty: prettify generated XML * indent: whitespace for indentation (only when pretty) * newline: newline char (only when pretty) + * allowEmpty: allow empty tags like instead of self-closing them like (only when pretty) + * spacebeforeslash: add the given space character(s) into self-closed tags like (only when pretty) * `xmldec` (default `{ 'version': '1.0', 'encoding': 'UTF-8', 'standalone': true }`: XML declaration attributes. * `xmldec.version` A version number string, e.g. 1.0