How to use
Convert basic XML elements and text content into JSON.
Useful for turning an XML response into JSON that front-end code can work with. Repeated sibling tags collapse into an array. Tags with attributes, or elements mixing text and children, report clearly as unsupported rather than dropping data silently.