attrkey (default: $): Prefix that is used to access the attributes. Version 0.1 default was @.
charkey (default: _): Prefix that is used to access the character content. Version 0.1 default was #.
explicitCharkey (default: false)
trim (default: false): Trim the whitespace at the beginning and end of text nodes.
normalizeTags (default: false): Normalize all tag names to lowercase.
normalize (default: false): Trim whitespaces inside text nodes.
explicitRoot (default: true): Set this if you want to get the root node in the resulting object.
emptyTag (default: ''): what will the value of empty nodes be.
explicitArray (default: true): Always put child nodes in an array if true; otherwise an array is created only if there is more than one.
ignoreAttrs (default: false): Ignore all XML attributes and only create text nodes.
mergeAttrs (default: false): Merge attributes and child elements as properties of the parent, instead of keying attributes off a child attribute object. This option is ignored if ignoreAttrs is true.
validator (default null): You can specify a callable that validates the resulting structure somehow, however you want. See unit tests for an example.
xmlns (default false): Give each element a field usually called '$ns' (the first character is the same as attrkey) that contains its local name and namespace URI.
explicitChildren (default false): Put child elements to separate property. Doesn't work with mergeAttrs = true. If element has no children then "children" won't be created. Added in 0.2.5.
childkey (default $$): Prefix that is used to access child elements if explicitChildren is set to true. Added in 0.2.5.
preserveChildrenOrder (default false): Modifies the behavior of explicitChildren so that the value of the "children" property becomes an ordered array. When this is true, every node will also get a #name field whose value will correspond to the XML nodeName, so that you may iterate the "children" array and still be able to determine node names. The named (and potentially unordered) properties are also retained in this configuration at the same level as the ordered "children" array. Added in 0.4.9.
charsAsChildren (default false): Determines whether chars should be considered children if explicitChildren is on. Added in 0.2.5.
includeWhiteChars (default false): Determines whether whitespace-only text nodes should be included. Added in 0.4.17.
async (default false): Should the callbacks be async? This might be an incompatible change if your code depends on sync execution of callbacks. Future versions of xml2js might change this default, so the recommendation is to not depend on sync execution anyway. Added in 0.2.6.
strict (default true): Set sax-js to strict or non-strict parsing mode. Defaults to true which is highly recommended, since parsing HTML which is not well-formed XML might yield just about anything. Added in 0.2.7.