RSS Git Download  Clone
..
  coerce.xml 631B Fix file name 13 years ago
  domain-reversible.json 737B adds json2xml parser 13 years ago
  domain.json 688B initial commit 13 years ago
  domain.xml 761B adds json2xml parser 13 years ago
  large.xml 31kB Refactor for perf sake. Add perf tests. 13 years ago
  README.md
# Simple SAX-based XML2JSON Parser. It does not parse the following elements: * CDATA sections * Processing instructions * XML declarations * Entity declarations * Comments ## Installation `npm install xml2json` ## Usage ```javascript var parser = require('xml2json'); var xml = "<foo>bar</foo>"; var json = parser.toJson(xml); //returns an string containing the json structure by default console.log(json); ``` * if you want to get the Javascript object then you might want to invoke parser.toJson(xml, {object: true}); * if you want a reversible json to xml then you should use parser.toJson(xml, {reversible: true}); ## License Copyright 2011 BugLabs Inc. All rights reserved.