revamped
This commit is contained in:
1 parent
322b182ca1
commit
93d4f838b6
50 files changed
+1016
-113
No files matched your search
Executable
+6
@@ -0,0 +1,6 @@
|
||||
DOMPurify.setConfig({ FORBID_TAGS: ['form', 'input', 'button', 'iframe', 'object'], FORBID_ATTR: ['onerror','onload','onclick','onmouseover','onfocus','srcdoc'], ALLOWED_URI_REGEXP: /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i });
|
||||
|
||||
function sanitizeMarkdown(md) {
|
||||
const html = marked.parse(md);
|
||||
return DOMPurify.sanitize(html);
|
||||
}
|
||||
Reference in new issue
Block a user