npm API examples

txml.getElementById (xml, id)

To find an element by ID. If you are only interested for the information on, a specific node, this is easy and fast, because not the entire xml text need to get parsed, but only the small section you are interested in.

  1. xml the xml string to search in.
  2. id the id of the element to find returns return one node