by component

component / domify

html -> elements

199 Stars 34 Forks Last release: Not found 103 Commits 16 Releases

Available items

No Items, yet!

The developer of this repository has not created any items for sale yet. Need a bug fixed? Help with integration? A different license? Create a request here:


Turn HTML into DOM elements x-browser.


Works out of the box in the browser:

var domify = require('domify');

document.addEventListener('DOMContentLoaded', function() { var el = domify('

Hello there

'); document.body.appendChild(el); });

You can also run it in node and iojs. Just pass a custom implementation of

var jsdom = require('jsdom').jsdom();


Hello there

', jsdom.defaultView.document);

Running tests

$ npm i -g component-test
$ make
$ component-test browser



We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.