{"_id":"dom-js","_rev":"19-b5b7351ec7051b648f2eaff6bdcaa653","name":"dom-js","dist-tags":{"latest":"0.0.9"},"versions":{"0.0.1":{"name":"dom-js","version":"0.0.1","dependencies":{"sax":">=0.1.5"},"directories":{"lib":"./lib"},"main":"./lib/dom-js","engines":{"node":"*"},"_npmJsonOpts":{"file":"/home/teknopaul/.npm/dom-js/0.0.1/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"dom-js@0.0.1","devDependencies":{},"_engineSupported":true,"_npmVersion":"1.0.15","_nodeVersion":"v0.5.1-pre","_defaultsLoaded":true,"dist":{"shasum":"41cedfefc65e2228628a3bc44b4f12448f9cea9d","tarball":"https://registry.npmjs.org/dom-js/-/dom-js-0.0.1.tgz","integrity":"sha512-l6zUCvXCln3i6XJZPXLZNAiKK2C2K0p7Pz6bex5Fv5CcXSmBr31bK9TCyE8YNUoIxoL2bJ21FKoQyebWFI6AWA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC1HqadQFAhkYhN8NP1nlaeeI9UUPaAX09C1rGjsRt9GgIgPSjhDsatCWpNei2wKk3ZyH7bwKWTlA6WUE58uvSBuT4="}]},"scripts":{}},"0.0.2":{"name":"dom-js","version":"0.0.2","description":"XML DOM based on sax","dependencies":{"sax":">=0.1.5"},"directories":{"lib":"./lib"},"main":"./lib/dom-js","engines":{"node":"*"},"_npmJsonOpts":{"file":"/home/teknopaul/.npm/dom-js/0.0.2/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"dom-js@0.0.2","devDependencies":{},"_engineSupported":true,"_npmVersion":"1.0.15","_nodeVersion":"v0.5.1-pre","_defaultsLoaded":true,"dist":{"shasum":"bbefe2d8648615ec9715e0b3458bfd6bd657aa7c","tarball":"https://registry.npmjs.org/dom-js/-/dom-js-0.0.2.tgz"},"scripts":{},"maintainers":[{"name":"teknopaul","email":"teknopaul@gmail.com"}]},"0.0.3":{"name":"dom-js","version":"0.0.3","description":"XML DOM based on sax","dependencies":{"sax":">=0.1.5"},"directories":{"lib":"./lib"},"main":"./lib/dom-js","engines":{"node":"*"},"_npmJsonOpts":{"file":"/home/teknopaul/.npm/dom-js/0.0.3/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"dom-js@0.0.3","devDependencies":{},"_engineSupported":true,"_npmVersion":"1.0.15","_nodeVersion":"v0.5.1-pre","_defaultsLoaded":true,"dist":{"shasum":"30a13e0db4fbb3fa204b3f74eb300a2dee07db76","tarball":"https://registry.npmjs.org/dom-js/-/dom-js-0.0.3.tgz","integrity":"sha512-/A07jXGbQQslVQ3Mo3Jp8T7NQoqO9WL08vcLt50BJd/4ulqr7jVEN8n66ZY2PAhpToyuVxHNcOLQqCoVaPNeSA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCpl73mzG1paU8uPGhb2v+WWc3lYt4MGlYZtdcUCLZE/AIgaarVr6Ew4ZgwTLgBSHp2IsYdONXO1Ftz/U53qxwuIPo="}]},"scripts":{},"maintainers":[{"name":"teknopaul","email":"teknopaul@gmail.com"}]},"0.0.5":{"name":"dom-js","version":"0.0.5","description":"XML DOM based on sax","dependencies":{"sax":">=0.1.5"},"directories":{"lib":"./lib"},"main":"./lib/dom-js","engines":{"node":"*"},"repository":{"type":"git","url":"git://github.com/teknopaul/dom-js.git"},"author":{"name":"teknopaul"},"_npmJsonOpts":{"file":"/home/teknopaul/.npm/dom-js/0.0.5/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"dom-js@0.0.5","devDependencies":{},"_engineSupported":true,"_npmVersion":"1.0.15","_nodeVersion":"v0.5.1-pre","_defaultsLoaded":true,"dist":{"shasum":"ca053aa0821a526ce0165a7b842554466e490e89","tarball":"https://registry.npmjs.org/dom-js/-/dom-js-0.0.5.tgz","integrity":"sha512-Y37WyLQ1OUKBdjL4cHRvzO5j+0IXasi2R31Gw7q8SSTXVHmGmJ1KJbv1NjsNHwv8qjNHBPG/w8kCPZreVvXGWg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICu1DMHFIL+gl9pFwUgyAjaKrEjwwSbr4dWpuRB2V27YAiA84V7BW9I6uC0C2uAOYdBL6iLDHfcxR7I0q670cnlXCQ=="}]},"scripts":{},"maintainers":[{"name":"teknopaul","email":"teknopaul@gmail.com"}]},"0.0.6":{"name":"dom-js","version":"0.0.6","description":"XML DOM based on sax","dependencies":{"sax":">=0.1.5"},"directories":{"lib":"./lib"},"main":"./lib/dom-js","engines":{"node":"*"},"repository":{"type":"git","url":"git://github.com/teknopaul/dom-js.git"},"author":{"name":"teknopaul"},"contributors":[{"name":"Rafal Jonca"}],"_npmUser":{"name":"teknopaul","email":"teknopaul@gmail.com"},"_id":"dom-js@0.0.6","devDependencies":{},"_engineSupported":true,"_npmVersion":"1.0.103","_nodeVersion":"v0.5.1-pre","_defaultsLoaded":true,"dist":{"shasum":"13a975d3d3ea12e09ff793d3a02b0f1e48223ebe","tarball":"https://registry.npmjs.org/dom-js/-/dom-js-0.0.6.tgz","integrity":"sha512-bVLY4I9bJOb/tjyI3RwQrKp8dE13kVO4/dmAcE8SO39pOf6a0o+Y2SZAd/JszXfjynB5GgD8PIEZGJUOeqkSaw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIA8DzHMXJ41FHdN3wruNFC0e7mxWd5U+Mg8ZSZHUIrvmAiAF3QDcY3Z5VWYSkxTjUJzVIZY5Fmqhpy3/1mCU9kz+sg=="}]},"maintainers":[{"name":"teknopaul","email":"teknopaul@gmail.com"}]},"0.0.7":{"name":"dom-js","version":"0.0.7","description":"XML DOM based on sax","dependencies":{"sax":">=0.1.5"},"directories":{"lib":"./lib"},"main":"./lib/dom-js","engines":{"node":"*"},"repository":{"type":"git","url":"git://github.com/teknopaul/dom-js.git"},"author":{"name":"teknopaul"},"contributors":[{"name":"Rafal Jonca"}],"_npmUser":{"name":"teknopaul","email":"teknopaul@gmail.com"},"_id":"dom-js@0.0.7","devDependencies":{},"_engineSupported":true,"_npmVersion":"1.0.103","_nodeVersion":"v0.5.1-pre","_defaultsLoaded":true,"dist":{"shasum":"e5b0b1a166f68ebc772a430802487a945ade1fda","tarball":"https://registry.npmjs.org/dom-js/-/dom-js-0.0.7.tgz","integrity":"sha512-cLLolqbODn8pmlstvgCSzdBB9/ZWvL8ods8w86Nhk/YIasro93cBQl9QWB5XHbKkef2Q3qh4pMJ8yb05kIwoIw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCXwLZI3KiPq5PBnOMPNQgi9Lvw7N6Im5fyramukrZ43gIgNEDo1hs2pSg1LjtBfOKKTO1H48mtmeVUbMB5wWfdOv8="}]},"maintainers":[{"name":"teknopaul","email":"teknopaul@gmail.com"}]},"0.0.8":{"name":"dom-js","version":"0.0.8","description":"XML DOM based on sax","dependencies":{"sax":">=0.1.5"},"directories":{"lib":"./lib"},"main":"./lib/dom-js","engines":{"node":"*"},"repository":{"type":"git","url":"git://github.com/teknopaul/dom-js.git"},"author":{"name":"teknopaul"},"contributors":[{"name":"Rafal Jonca"},{"name":"Chanwit Kaewkasi"}],"_npmJsonOpts":{"file":"/home/teknopaul/.npm/dom-js/0.0.8/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"dom-js@0.0.8","devDependencies":{},"_engineSupported":true,"_npmVersion":"1.0.18","_nodeVersion":"v0.5.1-pre","_defaultsLoaded":true,"dist":{"shasum":"fed239267cefaf543740626c10ba27383b0d8f2b","tarball":"https://registry.npmjs.org/dom-js/-/dom-js-0.0.8.tgz","integrity":"sha512-9JFyhtqrkhFO3LPPaNzlusBeBrDpQrFNXIq4mbuwYRrW9v6rRzYOA3BjGHo7eDpaYVuHvblYexefvZO803hs8A==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCrBgKe9v1pBO3ITK95csnGKIiuZabv+QpFkXW+yRMn9wIgWobMtc/S+uSZsKBhmQ30zhuVq21W23EQQDCw9wmo5Zs="}]},"scripts":{},"maintainers":[{"name":"teknopaul","email":"teknopaul@gmail.com"}]},"0.0.9":{"name":"dom-js","version":"0.0.9","description":"XML DOM based on sax","dependencies":{"sax":">=0.1.5"},"directories":{"lib":"./lib"},"main":"./lib/dom-js","engines":{"node":"*"},"repository":{"type":"git","url":"git://github.com/teknopaul/dom-js.git"},"author":{"name":"teknopaul"},"contributors":[{"name":"Rafal Jonca"},{"name":"Chanwit Kaewkasi"}],"_npmUser":{"name":"teknopaul","email":"teknopaul@gmail.com"},"_id":"dom-js@0.0.9","devDependencies":{},"optionalDependencies":{},"_engineSupported":true,"_npmVersion":"1.1.21","_nodeVersion":"v0.6.18","_defaultsLoaded":true,"dist":{"shasum":"2d6dd6c211af018f003f30edf5688f1ef86f15a7","tarball":"https://registry.npmjs.org/dom-js/-/dom-js-0.0.9.tgz","integrity":"sha512-RUgHZsozT+w9XlznVysC5uzbRufcjkqGFmRiOKbnUZzbUSBgGRoP3S2K1i1papT5XXMgDK1PuoxrsFBzP49/fA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCcDi0Zsdhg0XRA6lXi8DiIOSuQGpfVssMhH+UY+VUc7gIhAO91m3R7m336T5alpomSHNhxoy46TNDNTkbg8l5GNQAQ"}]},"readme":"# dom-js #\n\ndom-js is a node module that creates a DOM from a String using sax-js.\n\nDomJS has a parse() method  that takes a string and a callback which is used when the DOM is ready, or if there is an error.\n\nThe object returned contains the root Element parsed to JavaScript objects.\n\ndom-js returns the following object types\n\n* Element \n* Text\n* Comment\n* CDATASection\n* ProcessingInstruction (only contained in the root Element)\n\nAn Element has a name, a map of attributes, and an array of children, so you can find everything.\n\nYou get a couple of convenience methods on Element   text()  and  firstChild()  usage is hopefully obvious and save some boiler plate null checking.\n\nThe Element object has a method toXml() which returns a String with whitespace in tact.\n\nFor example \n\n    var util = require('util');\n    var DomJS = require(\"dom-js\").DomJS;\n\n    var domjs = new DomJS();\n\n    var string = '<xml><!-- the comment --><elem someAtt=\"fat &amp; red\">Hello &amp; World</elem></xml>';\n    domjs.parse(string, function(err, dom) {\n    \tconsole.log(util.inspect(dom, false, 23));\n    \tconsole.log(\"serializes to : \" + dom.toXml());\n    });\n\n\n## Examples\n\nThe /example/ folder in the npm package includes examples that console.log() the returned object.\n\n## Gotchas (that I can fix if it bothers anyone)\n\nAn empty tag <a></a>  will always be serialized in the short form <a/>.\n\nProcessingInstructions i.e. <?xml version=\"1.0\" encoding=\"UTF-8\"?>  are ignored and dropped by default, for backwards compatibility.\nIf you want to include processing instructions set the parseProcessingInstructions flag to true before calling parse().\n\n    var domjs = new DomJS();\n    domjs.parseProcessingInstructions = true;\n   \nThe first|root Element will contain an array called processingInstructions if the input document has any, otherwise processingInstructions is undefined.\nOutput of each processing instruction is always on a newline even if whitespace is different in the input document.\n\nSax strict parsing is on by default, and can be turned off by setting the strict flag.\n\n    var domjs = new DomJS();\n    domjs.strict = false;\n\nAn instance of DomJS should only be used once, but if you must reuse, call reset() before re-calling parse(). \nreset() does NOT reset the strict or processingInstructions flags.\n\n","maintainers":[{"name":"teknopaul","email":"teknopaul@gmail.com"}]}},"maintainers":[{"name":"teknopaul","email":"teknopaul@gmail.com"}],"time":{"modified":"2022-06-30T11:44:11.073Z","created":"2011-07-21T18:17:31.997Z","0.0.1":"2011-07-21T18:17:35.454Z","0.0.2":"2011-08-15T18:27:03.319Z","0.0.3":"2011-08-28T19:15:27.206Z","0.0.5":"2011-09-22T21:12:45.474Z","0.0.6":"2011-11-04T17:40:20.501Z","0.0.7":"2012-04-13T21:04:14.614Z","0.0.8":"2012-05-22T21:04:11.821Z","0.0.9":"2012-07-08T21:09:24.673Z"},"description":"XML DOM based on sax","author":{"name":"teknopaul"},"repository":{"type":"git","url":"git://github.com/teknopaul/dom-js.git"}}