{"name":"dom-lite","version":"0.1.6","stability":2,"license":"MIT","author":{"name":"Lauri Rooden","email":"lauri@rooden.ee"},"description":"A minimal DOM implementation","keywords":["dom"],"main":"index.js","scripts":{"build":"node node_modules/buildman/index.js --all","travis-test":"istanbul cover ./tests/index.js && (coveralls < coverage/lcov.info || exit 0)","test":"node tests/index.js"},"repository":{"type":"git","url":"git://github.com/litejs/dom-lite.git"},"bugs":{"url":"https://github.com/litejs/dom-lite/issues"},"devDependencies":{"buildman":"*","tape":"2.12.x"},"gitHead":"dc0107fcde575bda8097ad13292fbc9910fa5e9a","homepage":"https://github.com/litejs/dom-lite","_id":"dom-lite@0.1.6","_shasum":"cbd4911715e2036b993d71f75a49215dbd16353a","_from":".","_npmVersion":"2.1.6","_nodeVersion":"0.10.33","_npmUser":{"name":"lauriro","email":"lauri@rooden.ee"},"maintainers":[{"name":"lauriro","email":"lauri@rooden.ee"}],"dist":{"shasum":"cbd4911715e2036b993d71f75a49215dbd16353a","tarball":"http://registry-npm.ywwl.com/dom-lite/download/dom-lite-0.1.6.tgz","integrity":"sha512-SXE7dZgi41PSmDuVBZvsoBTlCc8s6bPU/G2Q+1KFsrh4/BQfcEDuTxFDfGOoGS8YACvJKOWYWsDx2ngZMxEthQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDlun/vC4quD26FQEJDhLGWF6JpffSow6GvCVve1cviDwIgIjngQa8Niq5jKjASCJUtCwn5TlK9hrqsprXTuI44Goc="}],"size":6119,"noattachment":false,"key":"/dom-lite/-/dom-lite-0.1.6.tgz"},"directories":{},"deprecated":"Moved to @litejs/dom","readme":"\n[1]: https://badgen.net/coveralls/c/github/litejs/dom-lite\n[2]: https://coveralls.io/r/litejs/dom-lite\n[3]: https://badgen.net/packagephobia/install/dom-lite\n[4]: https://packagephobia.now.sh/result?p=dom-lite\n[5]: https://badgen.net/badge/icon/Buy%20Me%20A%20Tea/orange?icon=kofi&label\n[6]: https://www.buymeacoffee.com/lauriro\n\n\nDOM lite &ndash; [![Coverage][1]][2] [![Size][3]][4] [![Buy Me A Tea][5]][6]\n========\n\nA small DOM implementation\nfor testing, server-side rendering and working with html files.\n\n\nExamples\n--------\n\n```javascript\nconst { document, DOMParser, XMLSerializer } = require(\"dom-lite\");\nconst { XMLHttpRequest } = require(\"dom-lite/xmlhttprequest\");\n\n// Use XMLHttpRequest in server side\nvar xhr = new XMLHttpRequest()\nxhr.open(\"GET\", \"https://litejs.com\")\nxhr.responseType = \"document\"\nxhr.onload = function() {\n\tvar doc = xhr.responseXML\n\t// Work with DOM in familiar way\n\tconsole.log(doc.querySelector(\"title\").textContent)\n}\nxhr.send()\n\n// Build DOM manually\nconst el = document.createElement(\"h1\");\nel.id = 123;\nel.className = \"large\";\n\nconst fragment = document.createDocumentFragment();\nconst text1 = document.createTextNode(\"hello\");\nconst text2 = document.createTextNode(\" world\");\n\nfragment.appendChild(text1);\nfragment.appendChild(text2);\nel.appendChild(fragment);\n\nel.innerHTML;\n// hello world\nel.innerHTML = \"<b>hello world</b>\";\nel.toString();\n// <h1 id=\"123\" class=\"large\"><b>hello world</b></h1>\n\n// minify output\nel.toString(true);\n// <h1 id=123 class=large><b>hello world</b></h1>\n\nel.querySelectorAll(\"b\");\n// [ \"<b>hello world</b>\" ]\n```\n\n## Contributing\n\nFollow [Coding Style Guide](https://github.com/litejs/litejs/wiki/Style-Guide)\n\nRun tests\n\n```\nnpm install\nnpm test\n```\n\n\n## External links\n\n[GitHub repo](https://github.com/litejs/dom-lite) |\n[npm package](https://npmjs.org/package/dom-lite) |\n[DOM spec](https://dom.spec.whatwg.org/) |\n[Selectors Level 3](http://www.w3.org/TR/selectors/) |\n[Coveralls coverage][2]  \n[Buy Me A Tea][6]\n\n\n## Licence\n\nCopyright (c) 2014-2023 Lauri Rooden &lt;lauri@rooden.ee&gt;  \n[The MIT License](http://lauri.rooden.ee/mit-license.txt)\n\n\n","publish_time":1414533169235,"_cnpm_publish_time":1414533169235,"dist-tags":{"latest":"23.2.1"}}