UNPKG

cleanview

Version:

Clean the content of html articles

58 lines (57 loc) 851 B
"use strict"; /* It's better to just work with the valid tags instead of removing all the invalid ones, which can be difficult for obscure tagnames */ Object.defineProperty(exports, "__esModule", { value: true }); const valid = [ "html", "body", "div", "main", "section", "article", "quote", "blockquote", "p", "h1", "h2", "h3", "h4", "h5", "h6", "br", "hr", "ul", "ol", "li", "table", "thead", "tbody", "tr", "th", "td", "a", "span", "small", "sub", "sup", "b", "i", "u", "s", "em", "strong", "q", "font", "center", "img", "figure", "figcaption", "picture", "pre", "code", "xmp", "iframe", // this will render only for videos ]; exports.default = valid;