npm.io
1.1.1 • Published 9 years ago

xml2js-es6-promise

Licence
ISC
Version
1.1.1
Deps
1
Vulns
1
Weekly
0
Stars
4
DeprecatedThis package is deprecated

xml2js-es6-promise

ES6 promise wrapper for xml2js

Installation

npm install xml2js-es6-promise

Usage

var xml2js = require('xml2js-es6-promise');

xml2js(xml).then(function(js) {
  console.log(JSON.stringify(js));
});

xml2js(xml, options).then(function(js) {
  console.log(JSON.stringify(js));
});

// e.g.
xml2js("<root>Hello xml2js!</root>", {trim: true}).then(function(js) {
  console.log(JSON.stringify(js));
});

Keywords