XmlStream is a Node.js XML stream parser and editor, based on node-expat (libexpat SAX parser binding).
This is why we've rolled our own stream parser that tries to address these shortcomings. It processes an XML stream chunk by chunk and fires events only for nodes of interest, matching them with CSS-like selectors.
dataon outgoing data chunk,
endwhen parsing has ended,
startElement[: selector]on opening tag for selector match,
updateElement[: selector]on finished node for selector match with its contents buffered,
endElement[: selector]on closing tag for selector match,
text[: selector]on tag text for selector match.
When adding listeners for
callback can modify the provided node, before it is sent to the consumer.
Selector syntax is CSS-like and currently supports:
parent > child
Take a look at the examples for more information.