leonidas-from-xiv/node-xml2js

XML to JavaScript object converter.

View on GitHub ↗Jump to charts ↓

Summary Information

Updated 52 minutes ago
Added to GitGenius on September 13th, 2026
Created on July 17th, 2010
Open Issues & Pull Requests: 249 (+0)
GitHub issues: Enabled
Number of forks: 602
Total Stargazers: 4,960 (+0)
Total Subscribers: 71 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 18.3 hours
Mean response time: 219.6 days
90th percentile: 963.6 days
Tracked items: 13

Most active contributors

Sign in to see contributor activity.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 16
New in 7 days: 0
Closed in 7 days: 0
Avg open age: 1,340 days
Stale 30+ days: 16
Stale 90+ days: 15

Recent activity

Opened in 7 days: 0
Closed in 7 days: 0
Comments in 7 days: 0
Events in 7 days: 0

Top labels

No label distribution available yet.

Most active issues this week

No issue events were indexed in the last 7 days.

Detailed Description

xml2js is an XML to JavaScript object converter that supports bidirectional conversion between XML and JavaScript objects.

The tool solves the problem of parsing XML and accessing its data in a straightforward, programmatic way without requiring compilation of a C parser. It uses the sax-js library for parsing and xmlbuilder-js for building, offering both simple callback-based parsing and promise-based interfaces. The converter can transform XML into JavaScript objects that are easy to navigate and manipulate, and can also convert objects back into XML.

Developers should choose this tool if they need lightweight XML parsing in Node.js without the overhead of a full DOM implementation. It suits projects that require basic XML-to-object conversion or JSON serialization of XML data. The README explicitly distinguishes itself from JSDom, noting that xml2js is appropriate for simple conversion tasks whereas JSDom is the choice for full DOM parsing requirements. The tool offers flexible usage patterns: a minimal shoot-and-forget approach for simple cases, a callback-based interface for more control, and promise-based parsing for modern async workflows. It handles multiple file parsing through parser reuse or reset, with the recommendation to create separate parser instances for reliability.

The project maintains a permissive API design that forgives common mistakes, such as allowing the Parser constructor to be called without the new keyword. Development activity shows consistent attention to usability details and backwards compatibility across versions, with incremental feature additions like promise support added over time rather than in breaking changes.