Partial implementation of the DOM, document for node.
Quick example
; // or var Document = require('html-document');const document = ; let textNode = document;let h1 = document;h1; h1;;
Purpose
The partial implementation allows you to build html like you would in the browser, with the DOM API.
This library will never implement all specifications of the W3C.
API
See the generated API here.
Examples
Inject window
, document
, Document
, DocumentFragment
, Node
and Event
in the global scope.
; // or var Document = require('html-document/lib/global'); let textNode = document;;
Create an HTML layout
let document = ;let fragment = document;fragment;let html = document;fragment;let head = document;html;let body = document;html;;