utils/xml
Documentation
- source: utils/xml.ts
Overview
Classes
XML
fromJson()
Converts a JSON input (either a JSON string or a raw JavaScript object) into an XML string.
Note: If a JavaScript object is passed, it is first stringified using JSON.stringify().
tsstatic fromJson(input: any): string;
Parameter Type Description inputanyThe JSON string or object to be converted to XML. Returns
- Type:
string- Description: The resulting XML content as a string.
toJson()
Converts an XML input (expected as an XML string) into a JSON formatted string.
tsstatic toJson(input: any): string;
Parameter Type Description inputanyThe XML string to be converted to JSON. Returns
- Type:
string- Description: The resulting JSON content as a string.
