2.2.3 • Published 4 years ago

xmlib v2.2.3

Weekly downloads
18
License
ISC
Repository
github
Last release
4 years ago

XML.js

XML library that works the same in the browser and in node.js

import XML from 'xmlib';

XML.parse & XML.stringify work like their JSON equivalents.

let xml = XML.parse(`<tag> <subtag> text </subtag> </tag>`);
XML.stringify(xml); // -> <tag> <subtag> text </subtag> </tag>

XML.transform applies an XSL Transformation.

XML.transform(xml,your_XSL_transformation);

added xpath function to every DOMNode to facilitate xpath evaluation

XML.parse(`<a> <b> <c> <d> hello </d> <d id='2'> hi </d> </c> </b> </a>`).xpath('//b')[0].xpath('.//d[@id=2]') // -> <d> hi </d>

https://www.npmjs.com/package/xmlib

2.2.3

4 years ago

2.2.2

4 years ago

2.2.1

4 years ago

2.1.9

4 years ago

2.1.8

4 years ago

2.1.7

4 years ago

2.1.4

4 years ago

2.1.6

4 years ago

2.1.5

4 years ago

2.1.2

4 years ago

2.1.3

4 years ago

2.1.1

4 years ago

2.0.9

4 years ago

2.1.0

4 years ago

2.0.8

4 years ago

2.0.5

4 years ago

2.0.7

4 years ago

2.0.6

4 years ago

2.0.4

4 years ago

2.0.2

4 years ago

2.0.1

5 years ago

2.0.0

5 years ago

1.0.0

5 years ago