Added toHTML() and docs.