From 8e6e755f793a02cf8986da1f8efb1c0c12d8d7a7 Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Sat, 26 Sep 2026 22:42:46 +0100 Subject: Escape markdown image alt text and src --- lib/writers/markdown-writer.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/writers/markdown-writer.js b/lib/writers/markdown-writer.js index 02961fe..399acac 100644 --- a/lib/writers/markdown-writer.js +++ b/lib/writers/markdown-writer.js @@ -29,7 +29,7 @@ function markdownImage(attributes) { var src = attributes.src || ""; var altText = attributes.alt || ""; if (src || altText) { - return {start: "![" + altText + "](" + src + ")"}; + return {start: "![" + escapeMarkdown(altText) + "](" + escapeMarkdown(src) + ")"}; } else { return {}; } -- cgit v1.2.3