{"name":"libxmljs","author":{"name":"Marco Rogers"},"contributors":[{"name":"Jeff Smick"}],"description":"libxml bindings for v8 javascript engine","version":"0.14.2","scripts":{"test":"node --expose_gc ./node_modules/.bin/nodeunit test","install":"node-gyp rebuild"},"repository":{"type":"git","url":"git+ssh://git@github.com/polotek/libxmljs.git"},"bugs":{"url":"http://github.com/polotek/libxmljs/issues"},"main":"./index","license":"MIT","engines":{"node":">=0.8.0"},"dependencies":{"bindings":"1.2.1","nan":"1.8.4"},"devDependencies":{"nodeunit":"0.9.0"},"gypfile":true,"gitHead":"0ccd9cce31acd72abc23a1031cbdd0cbc96b3d1c","homepage":"https://github.com/polotek/libxmljs#readme","_id":"libxmljs@0.14.2","_shasum":"e9eda18fc55fbed98dac8ba7e44f4c26bb10ac2d","_from":".","_npmVersion":"2.11.1","_nodeVersion":"2.3.0","_npmUser":{"name":"defunctzombie","email":"shtylman@gmail.com"},"dist":{"shasum":"e9eda18fc55fbed98dac8ba7e44f4c26bb10ac2d","tarball":"http://registry-npm.ywwl.com/libxmljs/download/libxmljs-0.14.2.tgz","integrity":"sha512-Nt7niI+kczUtg/UV7mO77AHcIPk2agulwt8hxS8nwEGGfbPSWsTBmaTZ5V5BjSzgRfkODdCW7g0EUljSkIwr/w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDHBNo0IoZnqjvLJZQbfD2N6FesoNI2Zy1nWf02qy08sgIhAKiSnywN9g/fmsmgAQVW1MDj3j3laLTZwF5OhbQaYShI"}],"size":1180639,"noattachment":false,"key":"/libxmljs/-/libxmljs-0.14.2.tgz"},"maintainers":[{"name":"polotek","email":"marco.rogers@gmail.com"},{"name":"defunctzombie","email":"shtylman@gmail.com"}],"directories":{},"readme":"# libxmljs\n\n[![npm version](https://badge.fury.io/js/libxmljs.svg)](https://badge.fury.io/js/libxmljs)\n[![Downloads monthly](https://img.shields.io/npm/dm/libxmljs.svg)](https://npmjs.org/package/libxmljs)\n[![Downloads total](https://img.shields.io/npm/dt/libxmljs.svg)](https://npmjs.org/package/libxmljs)\n[![Test & Upload](https://github.com/libxmljs/libxmljs/actions/workflows/test-deploy.yml/badge.svg)](https://github.com/libxmljs/libxmljs/actions/workflows/test-deploy.yml)\n\n`npm install libxmljs`\n\nNodeJS bindings for [libxml2](https://en.wikipedia.org/wiki/Libxml2) written in\nTypescript\n\n## Documentation\n\n[https://libxmljs.github.io/libxmljs/](https://libxmljs.github.io/libxmljs/)\n\n## Examples\n\nFor more examples, check out the [test suite](https://github.com/libxmljs/libxmljs/tree/master/test).\n\n```javascript\nimport libxmljs from \"libxmljs\";\n\nlibxmljs\n    .parseXmlAsync(\n        `\n        <?xml version=\"1.0\" encoding=\"UTF-8\"?>\n        <root>\n            <child foo=\"bar\">\n            <grandchild baz=\"fizbuzz\">grandchild content</grandchild>\n            </child>\n            <sibling>with content!</sibling>\n        </root>\n        `\n    )\n    .then((xmlDoc) => {\n        const gchild = xmlDoc.find(\"//grandchild\")[0];\n\n        console.log(gchild.text()); // prints \"grandchild content\"\n\n        const child = xmlDoc.root()?.child(0);\n\n        console.log(child?.getAttribute(\"foo\")?.value()); // prints \"bar\"\n    });\n```\n\n## Package Scripts\n\n`npm run init-submodules`\n\n> Clones libxml2 source code to `vendor/libxml2`\n\n`npm run configure`\n\n> Generate new cmake config headers with cmake in vendor/libxml2.config. Used when updating to a new libxml2 version.\n\n`npm run build`\n\n> Build the C++ source code using node-gyp\n\n`npm run swig`\n\n> Generate a new `src/libxml2.cc` and `swig.xml` file by processing the native code using SWIG. Used when making changes\n> to native code or any of the SWIG interface files (src/\\*.i)\n\n`npm run tsgenerate`\n\n> Generates typescript definitons for native bindings exports. Used when changes are made to native exports.\n> Auto-generates `constants.ts`, `functions.ts`, `types.ts`, and `variables.ts` within `lib/bindings/`\n\n`npm run tsc`\n\n> Compiles Typescript within `lib/` and outputs it to `dist/` Use `npm run dev` to put Typescript compiler into watch\n> mode.\n\n`npm run test`\n\n> Runs all tests in `test/` using nodeunit. Use `npm run test -- -t TEST_NAME` to run a specific test.\n\n`npm run docs`\n\n> Generates `docs/` using Typedoc\n","publish_time":1435105508312,"_cnpm_publish_time":1435105508312,"dist-tags":{"latest":"1.0.11"}}