Node.normalize()
Method Description |
Puts all text nodes underneath a node, including attribute nodes, into a normal form. In normal form, only structure (such as elements, comments, processing instructions, CDATA sections, and entity references) separates text nodes. After normalization, there are no adjacent or empty text nodes. Use this method if you require a particular document tree structure and want to make sure that the XML DOM view of a document is identical when you save and reload it. |
Returns |
void |
Supported Script Types |
Client and server scripts For more information, see SuiteScript 2.x Script Types. |
Governance |
None |
Module |
|
Since |
2015.2 |
Syntax
The following code sample shows the syntax for this member. It is not a functional example. For a complete script example, see N/xml Module Script Samples.
//Add additional code
...
node.normalize();
...
//Add additional code