diff --git a/src/services/utilServices/Sanitizer.ts b/src/services/utilServices/Sanitizer.ts new file mode 100644 index 000000000..741306547 --- /dev/null +++ b/src/services/utilServices/Sanitizer.ts @@ -0,0 +1,42 @@ +import DOMPurify from "isomorphic-dompurify" + +DOMPurify.setConfig({ + ADD_TAGS: ["iframe", "#comment", "script"], + ADD_ATTR: [ + "allow", + "allowfullscreen", + "frameborder", + "scrolling", + "marginheight", + "marginwidth", + "target", + "async", + ], + // required in case