A simple HTMLElement shim on the server.
This is a partial implementation of HTMLElement, to get client-side templates (such as hyperscript) working in node!
The current implementation is fully compatible with hyperscript.
Note: adds "document" to globals.
- createElement(nodeName)
- createTextNode(value)
- appendChild(node)
- replaceChild(node)
- removeChild(node)
- insertBefore(new, existing)
- toString()
- setAttribute(name, value)
- getAttribute(name)
- setProperty(name, value)
- getProperty(name)
- innerHTML()
- outerHTML()
- textContent()
Setters update existing objects, otherwise create anew;
- innerHTML
- outerHTML
- textContent
- attribute.value
- attribute.name
- everything else
- Your PR to make this a more accurate implementation
MIT