From 4079fa097543fdd1ae9d97ea6b9505fcb04863db Mon Sep 17 00:00:00 2001 From: FragginWagon Date: Wed, 28 Jan 2026 20:23:18 +0000 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20Configure=20highlight.js=20to=20han?= =?UTF-8?q?dle=20HTML=20safely=20with=20updated=20settings?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- code/websites/pokedex.online/src/directives/highlight.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/websites/pokedex.online/src/directives/highlight.js b/code/websites/pokedex.online/src/directives/highlight.js index 4387978..37d2b90 100644 --- a/code/websites/pokedex.online/src/directives/highlight.js +++ b/code/websites/pokedex.online/src/directives/highlight.js @@ -22,6 +22,8 @@ function applyHighlight(el, theme = 'github-dark') { } try { + // Configure highlight.js to handle HTML safely + hljs.configure({ useBR: false }); hljs.highlightElement(el); // Remove any existing theme classes el.className = el.className.replace(/hljs-theme-\w+/, '');