postboy
Version:
A command line tool to build emails
12 lines (11 loc) • 316 B
JavaScript
var $$ = function (html) { return require('cheerio').load(html,{decodeEntities:false, xmlMode:true}); };
module.exports = function (body, output, enable) {
if(enable){
var $ = $$(body);
$('[class]').each(function () {
$(this).removeAttr('class');
});
body = $.html();
}
output(body);
};