You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jan 7, 2021. It is now read-only.
Copy file name to clipboardExpand all lines: README.md
+4-1Lines changed: 4 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -54,14 +54,15 @@ var options = {
54
54
sanitize:true,
55
55
trim:true,
56
56
arrayNotation:false
57
+
alternateTextNode:false
57
58
};
58
59
```
59
60
60
61
***object:** Returns a Javascript object instead of a JSON string
61
62
***reversible:** Makes the JSON reversible to XML (*)
62
63
***coerce:** Makes type coercion. i.e.: numbers and booleans present in attributes and element values are converted from string to its correspondent data types. Coerce can be optionally defined as an object with specific methods of coercion based on attribute name or tag name, with fallback to default coercion.
63
64
***trim:** Removes leading and trailing whitespaces as well as line terminators in element values.
64
-
***arrayNotation:** XML child nodes are always treated as arrays
65
+
***arrayNotation:** XML child nodes are always treated as arrays NB: you can specify a selective array of nodes for this to apply to instead of the whole document.
65
66
***sanitize:** Sanitizes the following characters present in element values:
66
67
67
68
```javascript
@@ -76,6 +77,8 @@ var chars = {
76
77
"'":'''
77
78
};
78
79
```
80
+
***alternateTextNode:** Changes the default textNode property from $t to _t when option is set to true. Alternatively a string can be specified which will override $t to what ever the string is.
0 commit comments