π¨ The ultimate agentic social media scheduling tool π€
TypeScript nextjsopen-sourceopen-source-social-media-scheduling-toolosspostiz-cloudpostiz-hostedredisscheduling-toolsocial-media-scheduling-tooltypescript
feat: safer replacement to avoid <Script /> injections
Nevo David9ed403aff288
diff --git a/libraries/helpers/src/utils/strip.html.validation.ts b/libraries/helpers/src/utils/strip.html.validation.tsindex 78c9a7b60..1843f9f0c 100644--- a/libraries/helpers/src/utils/strip.html.validation.ts+++ b/libraries/helpers/src/utils/strip.html.validation.ts@@ -138,7 +138,7 @@ export const stripHtmlValidation = (none = false): string => {if (type === 'html') {- return value;+ return striptags(value, ['ul', 'ol', 'li', 'h1', 'h2', 'h3', 'p', 'strong', 'u']);}if (type === 'markdown') {@@ -178,7 +178,6 @@ export const convertLinkedinMention = (value: string) => {return value.replace(/<span.+?data-linkedin-id="(.+?)".+?>(.+?)<\/span>/gi,(match, id, name) => {- console.log(id, name);return `@[${name.replace('@', '')}](${id})`;});