package
Convert PostHTML tree to Bemjson tree
npm install posthtml-bemjsonGitHub-flavored package documentation.
Across all versions.
Download trend unavailable.
Runtime metadata.
Tagged topics.
PostHTML plugin to convert PostHTML tree to Bemjson tree
var posthtml = require('posthtml'),
html = '<html><head><title>Wow</title></head><body><div class="button"><div class="button__text">Text</div></div></body></html>';
var bemjson = posthtml()
.use(require('posthtml-bemjson'))
.process(html, { sync: true }).tree;npm run test