labset-kingdom-js

labset kingdom js


Keywords
labset, kingdom, xml, dom
License
Apache-2.0
Install
npm install labset-kingdom-js@0.0.1

Documentation

labset-kingdom-js

experimenting with DOM and reflection, alternative fro xml2json conversions.

install it

npm install labset-kingdom-js --save

use it

``` let KingDOM = require('kingdomjs');

let atomString = 'someIdsome title'; let atomEntry = new KingDOM(atomString).entry[0];

console.log(atomEntry.id[0]['#text']); // out : someId console.log(atomEntry.title[0]['#text']); // out : some title console.log(atomEntry.title[0]['@type']); // out : text

// serialize to string console.log(atomEntry['@toString']); ```

dev

npm run test:watch # run tests and watch for changes npm run coverage # generate coverage reports npm run lint # generate lint report

licence

Apache-2.0