npm.io
1.0.0 • Published 8 years ago

posthtml-rename-tags

Licence
MIT
Version
1.0.0
Deps
1
Vulns
0
Weekly
0

posthtml-rename-tags

PostHTMLRenameTags is plugin for PostHTML. It replace HTML tags with new tag.

Usage

var posthtml = require('posthtml'),
    html = '<div class="wow">OMG</div>';

posthtml([ require('posthtml-rename-tags')({
    '.wow' : 'span'
})])
    .process(html)
    .then(function(result) {
        console.log(result);
    });

// <span class="wow">OMG</span>

Keywords